Pharo 2.0 scriptaculous does not work

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
32 messages Options
12
Reply | Threaded
Open this post in threaded view
|

Pharo 2.0 scriptaculous does not work

Sabine Manaa
I am a little bit confused and need your help.

Yesterday I moved from Pharo 1.4 to Pharo 2.0.
(In Pharo 1.4. I used the one-click-package).

After moving to 2.0, first it seemed that all worked but now I have the following problem:

Buttons like this:

        html button
                onClick:
                                (html prototype evaluator
                                                callback: [ :script |
                                                                        self halt.
                                                                        2 inspect ];
                                                return: false);
                with: '??'

Dont work (also some other things but I assume that all has the same reason).
Click it - nothing happens.

After some investigation I found out that the scriptaculous example
http://localhost:8083/javascript/scriptaculous
does not work either.
Instead of counting it re-renders the page itself again within the  example.

I took the fresh 2.0. installation (windows) and loaded Seaside and JQueryWidgetBox.

<script src="/files/PTDevelopmentLibrary/prototype.js" type="text/javascript">
<script src="/files/SUDevelopmentLibrary/scriptaculous.js" type="text/javascript">
Is in my html code.

Possibly there is somtehing more to load now?
Possibly scriptaculous is not the reason?

Took me several hours now, help would be fine.
Sabine
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Johan Brichau-2
Sabine,

You are probably using the Zinc-Seaside adapter?
If you load latest Zinc packages, this bug will go away.

Johan

On 06 Jun 2013, at 13:02, Sabine Knöfel <[hidden email]> wrote:

> I am a little bit confused and need your help.
>
> Yesterday I moved from Pharo 1.4 to Pharo 2.0.
> (In Pharo 1.4. I used the one-click-package).
>
> After moving to 2.0, first it seemed that all worked but now I have the
> following problem:
>
> Buttons like this:
>
> html button
> onClick:
> (html prototype evaluator
> callback: [ :script |
> self halt.
> 2 inspect ];
> return: false);
> with: '??'
>
> Dont work (also some other things but I assume that all has the same
> reason).
> Click it - nothing happens.
>
> After some investigation I found out that the scriptaculous example
> http://localhost:8083/javascript/scriptaculous
> does not work either.
> Instead of counting it re-renders the page itself again within the  example.
>
> I took the fresh 2.0. installation (windows) and loaded Seaside and
> JQueryWidgetBox.
>
> <script src="/files/PTDevelopmentLibrary/prototype.js"
> type="text/javascript">
> <script src="/files/SUDevelopmentLibrary/scriptaculous.js"
> type="text/javascript">
> Is in my html code.
>
> Possibly there is somtehing more to load now?
> Possibly scriptaculous is not the reason?
>
> Took me several hours now, help would be fine.
> Sabine
>
>
>
> --
> View this message in context: http://forum.world.st/Pharo-2-0-scriptaculous-does-not-work-tp4691931.html
> Sent from the Seaside General mailing list archive at Nabble.com.
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Sabine Manaa
Hi Johann,

can you please tell me exactly which versions to load?

After loading Seaside from config browser in a new 2.0 Image, I have 
ConfigurationOfZincHTTPComponents-SvenVanCaekenberghe.48 (newest) which loads
Zinc-Seaside-SvenVanCaekenberghe.37 (not newest)

Loading then
Zinc-Seaside-SvenVanCaekenberghe.40 (newest) does not help

Both does not work for scriptaculous.

Sabine


On Thu, Jun 6, 2013 at 3:57 PM, Johan Brichau <[hidden email]> wrote:
Sabine,

You are probably using the Zinc-Seaside adapter?
If you load latest Zinc packages, this bug will go away.

Johan

On 06 Jun 2013, at 13:02, Sabine Knöfel <[hidden email]> wrote:

> I am a little bit confused and need your help.
>
> Yesterday I moved from Pharo 1.4 to Pharo 2.0.
> (In Pharo 1.4. I used the one-click-package).
>
> After moving to 2.0, first it seemed that all worked but now I have the
> following problem:
>
> Buttons like this:
>
>       html button
>               onClick:
>                               (html prototype evaluator
>                                               callback: [ :script |
>                                                                       self halt.
>                                                                       2 inspect ];
>                                               return: false);
>               with: '??'
>
> Dont work (also some other things but I assume that all has the same
> reason).
> Click it - nothing happens.
>
> After some investigation I found out that the scriptaculous example
> http://localhost:8083/javascript/scriptaculous
> does not work either.
> Instead of counting it re-renders the page itself again within the  example.
>
> I took the fresh 2.0. installation (windows) and loaded Seaside and
> JQueryWidgetBox.
>
> <script src="/files/PTDevelopmentLibrary/prototype.js"
> type="text/javascript">
> <script src="/files/SUDevelopmentLibrary/scriptaculous.js"
> type="text/javascript">
> Is in my html code.
>
> Possibly there is somtehing more to load now?
> Possibly scriptaculous is not the reason?
>
> Took me several hours now, help would be fine.
> Sabine
>
>
>
> --
> View this message in context: http://forum.world.st/Pharo-2-0-scriptaculous-does-not-work-tp4691931.html
> Sent from the Seaside General mailing list archive at Nabble.com.
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside


_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Sven Van Caekenberghe-2
Hi,

On 07 Jun 2013, at 08:39, Sabine Knöfel <[hidden email]> wrote:

> Hi Johann,
>
> can you please tell me exactly which versions to load?
>
> After loading Seaside from config browser in a new 2.0 Image, I have
> ConfigurationOfZincHTTPComponents-SvenVanCaekenberghe.48 (newest) which loads
> Zinc-Seaside-SvenVanCaekenberghe.37 (not newest)
>
> Loading then
> Zinc-Seaside-SvenVanCaekenberghe.40 (newest) does not help

Some recent changes to Zinc apparently resulted in some compatibility problems with Seaside. We fixed already at least one of them. For me, Seaside 3.1 in Pharo 2.0 now seems to work OK.

Now, ConfigurationOfZincHTTPComponents does _not_ specify which version of Zinc-Seaside should be loaded. It is not even in the config. It is Seaside that depends on Zinc and the adaptor, the other way around in not possible. It seems that somehow, the latest Zinc was loaded and not the latest adaptor, which matches it.

> Both does not work for scriptaculous.

How can I easily see what goes wrong ? Please keep in mind that advanced Seaside stuff is hard for me...

Sven

> Sabine
>
>
> On Thu, Jun 6, 2013 at 3:57 PM, Johan Brichau <[hidden email]> wrote:
> Sabine,
>
> You are probably using the Zinc-Seaside adapter?
> If you load latest Zinc packages, this bug will go away.
>
> Johan
>
> On 06 Jun 2013, at 13:02, Sabine Knöfel <[hidden email]> wrote:
>
> > I am a little bit confused and need your help.
> >
> > Yesterday I moved from Pharo 1.4 to Pharo 2.0.
> > (In Pharo 1.4. I used the one-click-package).
> >
> > After moving to 2.0, first it seemed that all worked but now I have the
> > following problem:
> >
> > Buttons like this:
> >
> >       html button
> >               onClick:
> >                               (html prototype evaluator
> >                                               callback: [ :script |
> >                                                                       self halt.
> >                                                                       2 inspect ];
> >                                               return: false);
> >               with: '??'
> >
> > Dont work (also some other things but I assume that all has the same
> > reason).
> > Click it - nothing happens.
> >
> > After some investigation I found out that the scriptaculous example
> > http://localhost:8083/javascript/scriptaculous
> > does not work either.
> > Instead of counting it re-renders the page itself again within the  example.
> >
> > I took the fresh 2.0. installation (windows) and loaded Seaside and
> > JQueryWidgetBox.
> >
> > <script src="/files/PTDevelopmentLibrary/prototype.js"
> > type="text/javascript">
> > <script src="/files/SUDevelopmentLibrary/scriptaculous.js"
> > type="text/javascript">
> > Is in my html code.
> >
> > Possibly there is somtehing more to load now?
> > Possibly scriptaculous is not the reason?
> >
> > Took me several hours now, help would be fine.
> > Sabine
> >
> >
> >
> > --
> > View this message in context: http://forum.world.st/Pharo-2-0-scriptaculous-does-not-work-tp4691931.html
> > Sent from the Seaside General mailing list archive at Nabble.com.
> > _______________________________________________
> > seaside mailing list
> > [hidden email]
> > http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Johan Brichau-2
Hi Sven,

On 07 Jun 2013, at 09:37, Sven Van Caekenberghe <[hidden email]> wrote:

> Now, ConfigurationOfZincHTTPComponents does _not_ specify which version of Zinc-Seaside should be loaded. It is not even in the config. It is Seaside that depends on Zinc and the adaptor, the other way around in not possible. It seems that somehow, the latest Zinc was loaded and not the latest adaptor, which matches it.

Seaside depends on the #stable version of Zinc but if Zinc upgrades its #stable version, the Seaside config should also upgrade its matching version of Zinc-Seaside.
Therefore, it seems natural that Zinc specifies the Zinc-Seaside version number that matches the Zinc version (as you say).

In earlier versions of Zinc, the Zinc-Seaside package was mentioned (version 1.0 and 1.1).

Or we adapt the Seaside config to depend on a specific Zinc version (which is less optimal imho)

What do you think?
Johan_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Sven Van Caekenberghe-2

On 07 Jun 2013, at 09:56, Johan Brichau <[hidden email]> wrote:

> Hi Sven,
>
> On 07 Jun 2013, at 09:37, Sven Van Caekenberghe <[hidden email]> wrote:
>
>> Now, ConfigurationOfZincHTTPComponents does _not_ specify which version of Zinc-Seaside should be loaded. It is not even in the config. It is Seaside that depends on Zinc and the adaptor, the other way around in not possible. It seems that somehow, the latest Zinc was loaded and not the latest adaptor, which matches it.
>
> Seaside depends on the #stable version of Zinc but if Zinc upgrades its #stable version, the Seaside config should also upgrade its matching version of Zinc-Seaside.
> Therefore, it seems natural that Zinc specifies the Zinc-Seaside version number that matches the Zinc version (as you say).

I am willing to do that (it sounds logical), but can that be done without depending on Seaside itself ? Because that does not sound practical, maybe reducing a circular dependency or at least an interference with the specific Seaside versions and groups that you initially want to load.

> In earlier versions of Zinc, the Zinc-Seaside package was mentioned (version 1.0 and 1.1).
>
> Or we adapt the Seaside config to depend on a specific Zinc version (which is less optimal imho)
>
> What do you think?
> Johan_______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Sabine Manaa
In reply to this post by Sven Van Caekenberghe-2
Hi Sven,

1) load Seaside config
2) WAComponent subclass: #TestView
        instanceVariableNames: ''
        classVariableNames: ''
        poolDictionaries: ''
        category: ''
3) TestView>>renderContentOn: html
        html button
                onClick:
                                (html prototype evaluator
                                                callback: [ :script |
                                                                        self halt.
                                                                        2 inspect ];
                                                return: false);
                with: 'Inspect'
4) (ZnZincServerAdaptor port: 8083) start.
5) (WAAdmin
                register: TestView
                asApplicationAt: 'test')
                addLibrary: PTDevelopmentLibrary;
                addLibrary: SUDevelopmentLibrary

6) In your browser, http://localhost:8083/test
Clicking at the button should start the debugger but that does not work.
In 1.4. that worked.

I am not sure perhaps it is me making sonething wrong I am not sure if
I did everything correct.
Advanced Seaside stuff is hard for me, too....;-)

Sabine

On Fri, Jun 7, 2013 at 9:37 AM, Sven Van Caekenberghe <[hidden email]> wrote:

> Hi,
>
> On 07 Jun 2013, at 08:39, Sabine Knöfel <[hidden email]> wrote:
>
>> Hi Johann,
>>
>> can you please tell me exactly which versions to load?
>>
>> After loading Seaside from config browser in a new 2.0 Image, I have
>> ConfigurationOfZincHTTPComponents-SvenVanCaekenberghe.48 (newest) which loads
>> Zinc-Seaside-SvenVanCaekenberghe.37 (not newest)
>>
>> Loading then
>> Zinc-Seaside-SvenVanCaekenberghe.40 (newest) does not help
>
> Some recent changes to Zinc apparently resulted in some compatibility problems with Seaside. We fixed already at least one of them. For me, Seaside 3.1 in Pharo 2.0 now seems to work OK.
>
> Now, ConfigurationOfZincHTTPComponents does _not_ specify which version of Zinc-Seaside should be loaded. It is not even in the config. It is Seaside that depends on Zinc and the adaptor, the other way around in not possible. It seems that somehow, the latest Zinc was loaded and not the latest adaptor, which matches it.
>
>> Both does not work for scriptaculous.
>
> How can I easily see what goes wrong ? Please keep in mind that advanced Seaside stuff is hard for me...
>
> Sven
>
>> Sabine
>>
>>
>> On Thu, Jun 6, 2013 at 3:57 PM, Johan Brichau <[hidden email]> wrote:
>> Sabine,
>>
>> You are probably using the Zinc-Seaside adapter?
>> If you load latest Zinc packages, this bug will go away.
>>
>> Johan
>>
>> On 06 Jun 2013, at 13:02, Sabine Knöfel <[hidden email]> wrote:
>>
>> > I am a little bit confused and need your help.
>> >
>> > Yesterday I moved from Pharo 1.4 to Pharo 2.0.
>> > (In Pharo 1.4. I used the one-click-package).
>> >
>> > After moving to 2.0, first it seemed that all worked but now I have the
>> > following problem:
>> >
>> > Buttons like this:
>> >
>> >       html button
>> >               onClick:
>> >                               (html prototype evaluator
>> >                                               callback: [ :script |
>> >                                                                       self halt.
>> >                                                                       2 inspect ];
>> >                                               return: false);
>> >               with: '??'
>> >
>> > Dont work (also some other things but I assume that all has the same
>> > reason).
>> > Click it - nothing happens.
>> >
>> > After some investigation I found out that the scriptaculous example
>> > http://localhost:8083/javascript/scriptaculous
>> > does not work either.
>> > Instead of counting it re-renders the page itself again within the  example.
>> >
>> > I took the fresh 2.0. installation (windows) and loaded Seaside and
>> > JQueryWidgetBox.
>> >
>> > <script src="/files/PTDevelopmentLibrary/prototype.js"
>> > type="text/javascript">
>> > <script src="/files/SUDevelopmentLibrary/scriptaculous.js"
>> > type="text/javascript">
>> > Is in my html code.
>> >
>> > Possibly there is somtehing more to load now?
>> > Possibly scriptaculous is not the reason?
>> >
>> > Took me several hours now, help would be fine.
>> > Sabine
>> >
>> >
>> >
>> > --
>> > View this message in context: http://forum.world.st/Pharo-2-0-scriptaculous-does-not-work-tp4691931.html
>> > Sent from the Seaside General mailing list archive at Nabble.com.
>> > _______________________________________________
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Johan Brichau-2
In reply to this post by Sven Van Caekenberghe-2

On 07 Jun 2013, at 10:03, Sven Van Caekenberghe <[hidden email]> wrote:

> I am willing to do that (it sounds logical), but can that be done without depending on Seaside itself ? Because that does not sound practical, maybe reducing a circular dependency or at least an interference with the specific Seaside versions and groups that you initially want to load.

If I am correct, that should not be a problem.

The Seaside30 config can specify to load the 'Zinc-Seaside' version as specified by the Zinc config.
All you have to do is list the Zinc-Seaside package in your version methods and make sure that it does not get loaded when not explicitly asking for it.
I believe that can be done by not putting it in the #default load group.

If you want your config to be complete, you can list a dependency on the Seaside project for the Zinc-Seaside package. This would only be loaded if somebody explicitly load the Zinc-Seaside package.

If that does not work, we need to ask the Metacello doctor ;-)

Johan_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Johan Brichau-2
In reply to this post by Sabine Manaa
Hi Sabine,

We are working on fixing the configs.

In the meantime, if you open the monticello browser on the Zinc repository and you load all the latest packages of Zinc, it really should work.
I had exactly the same problem yesterday and this fixed it.

Johan

On 07 Jun 2013, at 10:09, Sabine Knöfel <[hidden email]> wrote:

> Hi Sven,
>
> 1) load Seaside config
> 2) WAComponent subclass: #TestView
> instanceVariableNames: ''
> classVariableNames: ''
> poolDictionaries: ''
> category: ''
> 3) TestView>>renderContentOn: html
> html button
> onClick:
> (html prototype evaluator
> callback: [ :script |
> self halt.
> 2 inspect ];
> return: false);
> with: 'Inspect'
> 4) (ZnZincServerAdaptor port: 8083) start.
> 5) (WAAdmin
> register: TestView
> asApplicationAt: 'test')
> addLibrary: PTDevelopmentLibrary;
> addLibrary: SUDevelopmentLibrary
>
> 6) In your browser, http://localhost:8083/test
> Clicking at the button should start the debugger but that does not work.
> In 1.4. that worked.
>
> I am not sure perhaps it is me making sonething wrong I am not sure if
> I did everything correct.
> Advanced Seaside stuff is hard for me, too....;-)
>
> Sabine
>
> On Fri, Jun 7, 2013 at 9:37 AM, Sven Van Caekenberghe <[hidden email]> wrote:
>> Hi,
>>
>> On 07 Jun 2013, at 08:39, Sabine Knöfel <[hidden email]> wrote:
>>
>>> Hi Johann,
>>>
>>> can you please tell me exactly which versions to load?
>>>
>>> After loading Seaside from config browser in a new 2.0 Image, I have
>>> ConfigurationOfZincHTTPComponents-SvenVanCaekenberghe.48 (newest) which loads
>>> Zinc-Seaside-SvenVanCaekenberghe.37 (not newest)
>>>
>>> Loading then
>>> Zinc-Seaside-SvenVanCaekenberghe.40 (newest) does not help
>>
>> Some recent changes to Zinc apparently resulted in some compatibility problems with Seaside. We fixed already at least one of them. For me, Seaside 3.1 in Pharo 2.0 now seems to work OK.
>>
>> Now, ConfigurationOfZincHTTPComponents does _not_ specify which version of Zinc-Seaside should be loaded. It is not even in the config. It is Seaside that depends on Zinc and the adaptor, the other way around in not possible. It seems that somehow, the latest Zinc was loaded and not the latest adaptor, which matches it.
>>
>>> Both does not work for scriptaculous.
>>
>> How can I easily see what goes wrong ? Please keep in mind that advanced Seaside stuff is hard for me...
>>
>> Sven
>>
>>> Sabine
>>>
>>>
>>> On Thu, Jun 6, 2013 at 3:57 PM, Johan Brichau <[hidden email]> wrote:
>>> Sabine,
>>>
>>> You are probably using the Zinc-Seaside adapter?
>>> If you load latest Zinc packages, this bug will go away.
>>>
>>> Johan
>>>
>>> On 06 Jun 2013, at 13:02, Sabine Knöfel <[hidden email]> wrote:
>>>
>>>> I am a little bit confused and need your help.
>>>>
>>>> Yesterday I moved from Pharo 1.4 to Pharo 2.0.
>>>> (In Pharo 1.4. I used the one-click-package).
>>>>
>>>> After moving to 2.0, first it seemed that all worked but now I have the
>>>> following problem:
>>>>
>>>> Buttons like this:
>>>>
>>>>      html button
>>>>              onClick:
>>>>                              (html prototype evaluator
>>>>                                              callback: [ :script |
>>>>                                                                      self halt.
>>>>                                                                      2 inspect ];
>>>>                                              return: false);
>>>>              with: '??'
>>>>
>>>> Dont work (also some other things but I assume that all has the same
>>>> reason).
>>>> Click it - nothing happens.
>>>>
>>>> After some investigation I found out that the scriptaculous example
>>>> http://localhost:8083/javascript/scriptaculous
>>>> does not work either.
>>>> Instead of counting it re-renders the page itself again within the  example.
>>>>
>>>> I took the fresh 2.0. installation (windows) and loaded Seaside and
>>>> JQueryWidgetBox.
>>>>
>>>> <script src="/files/PTDevelopmentLibrary/prototype.js"
>>>> type="text/javascript">
>>>> <script src="/files/SUDevelopmentLibrary/scriptaculous.js"
>>>> type="text/javascript">
>>>> Is in my html code.
>>>>
>>>> Possibly there is somtehing more to load now?
>>>> Possibly scriptaculous is not the reason?
>>>>
>>>> Took me several hours now, help would be fine.
>>>> Sabine
>>>>
>>>>
>>>>
>>>> --
>>>> View this message in context: http://forum.world.st/Pharo-2-0-scriptaculous-does-not-work-tp4691931.html
>>>> Sent from the Seaside General mailing list archive at Nabble.com.
>>>> _______________________________________________
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Sabine Manaa
Hi Johan,

yes, I have it now.
I choose the newest from everyting without thinking :-)
Thank you.

Sabine

On Fri, Jun 7, 2013 at 10:13 AM, Johan Brichau <[hidden email]> wrote:

> Hi Sabine,
>
> We are working on fixing the configs.
>
> In the meantime, if you open the monticello browser on the Zinc repository and you load all the latest packages of Zinc, it really should work.
> I had exactly the same problem yesterday and this fixed it.
>
> Johan
>
> On 07 Jun 2013, at 10:09, Sabine Knöfel <[hidden email]> wrote:
>
>> Hi Sven,
>>
>> 1) load Seaside config
>> 2) WAComponent subclass: #TestView
>>       instanceVariableNames: ''
>>       classVariableNames: ''
>>       poolDictionaries: ''
>>       category: ''
>> 3) TestView>>renderContentOn: html
>>       html button
>>               onClick:
>>                               (html prototype evaluator
>>                                               callback: [ :script |
>>                                                                       self halt.
>>                                                                       2 inspect ];
>>                                               return: false);
>>               with: 'Inspect'
>> 4) (ZnZincServerAdaptor port: 8083) start.
>> 5) (WAAdmin
>>               register: TestView
>>               asApplicationAt: 'test')
>>               addLibrary: PTDevelopmentLibrary;
>>               addLibrary: SUDevelopmentLibrary
>>
>> 6) In your browser, http://localhost:8083/test
>> Clicking at the button should start the debugger but that does not work.
>> In 1.4. that worked.
>>
>> I am not sure perhaps it is me making sonething wrong I am not sure if
>> I did everything correct.
>> Advanced Seaside stuff is hard for me, too....;-)
>>
>> Sabine
>>
>> On Fri, Jun 7, 2013 at 9:37 AM, Sven Van Caekenberghe <[hidden email]> wrote:
>>> Hi,
>>>
>>> On 07 Jun 2013, at 08:39, Sabine Knöfel <[hidden email]> wrote:
>>>
>>>> Hi Johann,
>>>>
>>>> can you please tell me exactly which versions to load?
>>>>
>>>> After loading Seaside from config browser in a new 2.0 Image, I have
>>>> ConfigurationOfZincHTTPComponents-SvenVanCaekenberghe.48 (newest) which loads
>>>> Zinc-Seaside-SvenVanCaekenberghe.37 (not newest)
>>>>
>>>> Loading then
>>>> Zinc-Seaside-SvenVanCaekenberghe.40 (newest) does not help
>>>
>>> Some recent changes to Zinc apparently resulted in some compatibility problems with Seaside. We fixed already at least one of them. For me, Seaside 3.1 in Pharo 2.0 now seems to work OK.
>>>
>>> Now, ConfigurationOfZincHTTPComponents does _not_ specify which version of Zinc-Seaside should be loaded. It is not even in the config. It is Seaside that depends on Zinc and the adaptor, the other way around in not possible. It seems that somehow, the latest Zinc was loaded and not the latest adaptor, which matches it.
>>>
>>>> Both does not work for scriptaculous.
>>>
>>> How can I easily see what goes wrong ? Please keep in mind that advanced Seaside stuff is hard for me...
>>>
>>> Sven
>>>
>>>> Sabine
>>>>
>>>>
>>>> On Thu, Jun 6, 2013 at 3:57 PM, Johan Brichau <[hidden email]> wrote:
>>>> Sabine,
>>>>
>>>> You are probably using the Zinc-Seaside adapter?
>>>> If you load latest Zinc packages, this bug will go away.
>>>>
>>>> Johan
>>>>
>>>> On 06 Jun 2013, at 13:02, Sabine Knöfel <[hidden email]> wrote:
>>>>
>>>>> I am a little bit confused and need your help.
>>>>>
>>>>> Yesterday I moved from Pharo 1.4 to Pharo 2.0.
>>>>> (In Pharo 1.4. I used the one-click-package).
>>>>>
>>>>> After moving to 2.0, first it seemed that all worked but now I have the
>>>>> following problem:
>>>>>
>>>>> Buttons like this:
>>>>>
>>>>>      html button
>>>>>              onClick:
>>>>>                              (html prototype evaluator
>>>>>                                              callback: [ :script |
>>>>>                                                                      self halt.
>>>>>                                                                      2 inspect ];
>>>>>                                              return: false);
>>>>>              with: '??'
>>>>>
>>>>> Dont work (also some other things but I assume that all has the same
>>>>> reason).
>>>>> Click it - nothing happens.
>>>>>
>>>>> After some investigation I found out that the scriptaculous example
>>>>> http://localhost:8083/javascript/scriptaculous
>>>>> does not work either.
>>>>> Instead of counting it re-renders the page itself again within the  example.
>>>>>
>>>>> I took the fresh 2.0. installation (windows) and loaded Seaside and
>>>>> JQueryWidgetBox.
>>>>>
>>>>> <script src="/files/PTDevelopmentLibrary/prototype.js"
>>>>> type="text/javascript">
>>>>> <script src="/files/SUDevelopmentLibrary/scriptaculous.js"
>>>>> type="text/javascript">
>>>>> Is in my html code.
>>>>>
>>>>> Possibly there is somtehing more to load now?
>>>>> Possibly scriptaculous is not the reason?
>>>>>
>>>>> Took me several hours now, help would be fine.
>>>>> Sabine
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> View this message in context: http://forum.world.st/Pharo-2-0-scriptaculous-does-not-work-tp4691931.html
>>>>> Sent from the Seaside General mailing list archive at Nabble.com.
>>>>> _______________________________________________
>> _______________________________________________
>> seaside mailing list
>> [hidden email]
>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Sabine Manaa
Another Point: I use this to get exchange rates from openexchangerates:

 (ZnClient new
                systemPolicy;
                http;
                host: 'openexchangerates.org'
                )
                        path: 'api/latest.json?app_id=2ddac6f47cf74936a920beb22ac55704'  ;
                        get

in 1.4 -> this works fine: {
  "disclaimer": "E..../",
  "license": "Data source....se/",
  "timestamp": 1370592069,
  "base": "USD",
  "rates": {
    "AED": 3.672719,
    "AFN": 54.766067,
    "ALL": 106.609251,
    "AMD": 418.215,
  ...

in 2.0 -> the result is a byte array. #[123 10 32 32 34 100 105 115 99
108 97 105

Do I have to change something here?
Sabine
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Sven Van Caekenberghe-2
Sabine,

On 07 Jun 2013, at 10:44, Sabine Knöfel <[hidden email]> wrote:

> Another Point: I use this to get exchange rates from openexchangerates:
>
> (ZnClient new
> systemPolicy;
> http;
> host: 'openexchangerates.org'
> )
> path: 'api/latest.json?app_id=2ddac6f47cf74936a920beb22ac55704'  ;
> get
>
> in 1.4 -> this works fine: {
>  "disclaimer": "E..../",
>  "license": "Data source....se/",
>  "timestamp": 1370592069,
>  "base": "USD",
>  "rates": {
>    "AED": 3.672719,
>    "AFN": 54.766067,
>    "ALL": 106.609251,
>    "AMD": 418.215,
>  ...
>
> in 2.0 -> the result is a byte array. #[123 10 32 32 34 100 105 115 99
> 108 97 105
>
> Do I have to change something here?
> Sabine

That is indeed a bug. Here is the fix (not yet in any config):

===
Name: Zinc-Resource-Meta-Core-SvenVanCaekenberghe.15
Author: SvenVanCaekenberghe
Time: 7 June 2013, 11:18:29.493 am
UUID: b1059f61-d7a1-44b0-bb0a-f558fbbec3c8
Ancestors: Zinc-Resource-Meta-Core-SvenVanCaekenberghe.14

Fixed a bug in ZnMimeType>>#isBinary (thx Sabine K for reporting this)
==

I would write your example as follows:

ZnClient new
        systemPolicy;
        http;
        host: 'openexchangerates.org';
        path: 'api/latest.json';
        queryAt: 'app_id' put: '2ddac6f47cf74936a920beb22ac55704';
        accept: ZnMimeType applicationJson;
        contentReader: [ :entity | NeoJSONReader fromString: entity contents ];
        get.

It integrates the JSON parsing step so you get a nice dictionary back. The systemPolicy with the accept makes sure you only do the parsing when application/json comes back. You can also add an #ifFail: block for general error handling should the request fail.

Sven_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Sabine Manaa
oh, my first bug ;-)
Thank you for the fast solution!

On Fri, Jun 7, 2013 at 11:23 AM, Sven Van Caekenberghe <[hidden email]> wrote:

> Sabine,
>
> On 07 Jun 2013, at 10:44, Sabine Knöfel <[hidden email]> wrote:
>
>> Another Point: I use this to get exchange rates from openexchangerates:
>>
>> (ZnClient new
>>               systemPolicy;
>>               http;
>>               host: 'openexchangerates.org'
>>               )
>>                       path: 'api/latest.json?app_id=2ddac6f47cf74936a920beb22ac55704'  ;
>>                       get
>>
>> in 1.4 -> this works fine: {
>>  "disclaimer": "E..../",
>>  "license": "Data source....se/",
>>  "timestamp": 1370592069,
>>  "base": "USD",
>>  "rates": {
>>    "AED": 3.672719,
>>    "AFN": 54.766067,
>>    "ALL": 106.609251,
>>    "AMD": 418.215,
>>  ...
>>
>> in 2.0 -> the result is a byte array. #[123 10 32 32 34 100 105 115 99
>> 108 97 105
>>
>> Do I have to change something here?
>> Sabine
>
> That is indeed a bug. Here is the fix (not yet in any config):
>
> ===
> Name: Zinc-Resource-Meta-Core-SvenVanCaekenberghe.15
> Author: SvenVanCaekenberghe
> Time: 7 June 2013, 11:18:29.493 am
> UUID: b1059f61-d7a1-44b0-bb0a-f558fbbec3c8
> Ancestors: Zinc-Resource-Meta-Core-SvenVanCaekenberghe.14
>
> Fixed a bug in ZnMimeType>>#isBinary (thx Sabine K for reporting this)
> ==
>
> I would write your example as follows:
>
> ZnClient new
>         systemPolicy;
>         http;
>         host: 'openexchangerates.org';
>         path: 'api/latest.json';
>         queryAt: 'app_id' put: '2ddac6f47cf74936a920beb22ac55704';
>         accept: ZnMimeType applicationJson;
>         contentReader: [ :entity | NeoJSONReader fromString: entity contents ];
>         get.
>
> It integrates the JSON parsing step so you get a nice dictionary back. The systemPolicy with the accept makes sure you only do the parsing when application/json comes back. You can also add an #ifFail: block for general error handling should the request fail.
>
> Sven_______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Sven Van Caekenberghe-2
In reply to this post by Johan Brichau-2
Johan,

On 07 Jun 2013, at 10:11, Johan Brichau <[hidden email]> wrote:

> On 07 Jun 2013, at 10:03, Sven Van Caekenberghe <[hidden email]> wrote:
>
>> I am willing to do that (it sounds logical), but can that be done without depending on Seaside itself ? Because that does not sound practical, maybe reducing a circular dependency or at least an interference with the specific Seaside versions and groups that you initially want to load.
>
> If I am correct, that should not be a problem.
>
> The Seaside30 config can specify to load the 'Zinc-Seaside' version as specified by the Zinc config.
> All you have to do is list the Zinc-Seaside package in your version methods and make sure that it does not get loaded when not explicitly asking for it.
> I believe that can be done by not putting it in the #default load group.

I just created ConfigurationOfZincHTTPComponents-SvenVanCaekenberghe.49 which now has a 'Seaside' group that loads the 'Zinc-Seaside' adaptor package with a specific version. It is of course not loaded by default.

> If you want your config to be complete, you can list a dependency on the Seaside project for the Zinc-Seaside package. This would only be loaded if somebody explicitly load the Zinc-Seaside package.

For now I skipped the dependency on Seaside, we'll see how it goes.

Sven

> If that does not work, we need to ask the Metacello doctor ;-)
>
> Johan_______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

--
Sven Van Caekenberghe
Proudly supporting Pharo
http://pharo.org
http://association.pharo.org
http://consortium.pharo.org




_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Paul DeBruicker
In reply to this post by Sabine Manaa
Are you using the Money library from squeaksource?




On Jun 7, 2013, at 2:34 AM, Sabine Knöfel <[hidden email]> wrote:

> oh, my first bug ;-)
> Thank you for the fast solution!
>
> On Fri, Jun 7, 2013 at 11:23 AM, Sven Van Caekenberghe <[hidden email]> wrote:
>> Sabine,
>>
>> On 07 Jun 2013, at 10:44, Sabine Knöfel <[hidden email]> wrote:
>>
>>> Another Point: I use this to get exchange rates from openexchangerates:
>>>
>>> (ZnClient new
>>>              systemPolicy;
>>>              http;
>>>              host: 'openexchangerates.org'
>>>              )
>>>                      path: 'api/latest.json?app_id=2ddac6f47cf74936a920beb22ac55704'  ;
>>>                      get
>>>
>>> in 1.4 -> this works fine: {
>>> "disclaimer": "E..../",
>>> "license": "Data source....se/",
>>> "timestamp": 1370592069,
>>> "base": "USD",
>>> "rates": {
>>>   "AED": 3.672719,
>>>   "AFN": 54.766067,
>>>   "ALL": 106.609251,
>>>   "AMD": 418.215,
>>> ...
>>>
>>> in 2.0 -> the result is a byte array. #[123 10 32 32 34 100 105 115 99
>>> 108 97 105
>>>
>>> Do I have to change something here?
>>> Sabine
>>
>> That is indeed a bug. Here is the fix (not yet in any config):
>>
>> ===
>> Name: Zinc-Resource-Meta-Core-SvenVanCaekenberghe.15
>> Author: SvenVanCaekenberghe
>> Time: 7 June 2013, 11:18:29.493 am
>> UUID: b1059f61-d7a1-44b0-bb0a-f558fbbec3c8
>> Ancestors: Zinc-Resource-Meta-Core-SvenVanCaekenberghe.14
>>
>> Fixed a bug in ZnMimeType>>#isBinary (thx Sabine K for reporting this)
>> ==
>>
>> I would write your example as follows:
>>
>> ZnClient new
>>        systemPolicy;
>>        http;
>>        host: 'openexchangerates.org';
>>        path: 'api/latest.json';
>>        queryAt: 'app_id' put: '2ddac6f47cf74936a920beb22ac55704';
>>        accept: ZnMimeType applicationJson;
>>        contentReader: [ :entity | NeoJSONReader fromString: entity contents ];
>>        get.
>>
>> It integrates the JSON parsing step so you get a nice dictionary back. The systemPolicy with the accept makes sure you only do the parsing when application/json comes back. You can also add an #ifFail: block for general error handling should the request fail.
>>
>> Sven_______________________________________________
>> seaside mailing list
>> [hidden email]
>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Sabine Manaa
I was using it but then I needed changes as far as I remember.
Now I have my own solution.
What is the background of your question?

On Fri, Jun 7, 2013 at 2:39 PM, Paul DeBruicker <[hidden email]> wrote:

> Are you using the Money library from squeaksource?
>
>
>
>
> On Jun 7, 2013, at 2:34 AM, Sabine Knöfel <[hidden email]> wrote:
>
>> oh, my first bug ;-)
>> Thank you for the fast solution!
>>
>> On Fri, Jun 7, 2013 at 11:23 AM, Sven Van Caekenberghe <[hidden email]> wrote:
>>> Sabine,
>>>
>>> On 07 Jun 2013, at 10:44, Sabine Knöfel <[hidden email]> wrote:
>>>
>>>> Another Point: I use this to get exchange rates from openexchangerates:
>>>>
>>>> (ZnClient new
>>>>              systemPolicy;
>>>>              http;
>>>>              host: 'openexchangerates.org'
>>>>              )
>>>>                      path: 'api/latest.json?app_id=2ddac6f47cf74936a920beb22ac55704'  ;
>>>>                      get
>>>>
>>>> in 1.4 -> this works fine: {
>>>> "disclaimer": "E..../",
>>>> "license": "Data source....se/",
>>>> "timestamp": 1370592069,
>>>> "base": "USD",
>>>> "rates": {
>>>>   "AED": 3.672719,
>>>>   "AFN": 54.766067,
>>>>   "ALL": 106.609251,
>>>>   "AMD": 418.215,
>>>> ...
>>>>
>>>> in 2.0 -> the result is a byte array. #[123 10 32 32 34 100 105 115 99
>>>> 108 97 105
>>>>
>>>> Do I have to change something here?
>>>> Sabine
>>>
>>> That is indeed a bug. Here is the fix (not yet in any config):
>>>
>>> ===
>>> Name: Zinc-Resource-Meta-Core-SvenVanCaekenberghe.15
>>> Author: SvenVanCaekenberghe
>>> Time: 7 June 2013, 11:18:29.493 am
>>> UUID: b1059f61-d7a1-44b0-bb0a-f558fbbec3c8
>>> Ancestors: Zinc-Resource-Meta-Core-SvenVanCaekenberghe.14
>>>
>>> Fixed a bug in ZnMimeType>>#isBinary (thx Sabine K for reporting this)
>>> ==
>>>
>>> I would write your example as follows:
>>>
>>> ZnClient new
>>>        systemPolicy;
>>>        http;
>>>        host: 'openexchangerates.org';
>>>        path: 'api/latest.json';
>>>        queryAt: 'app_id' put: '2ddac6f47cf74936a920beb22ac55704';
>>>        accept: ZnMimeType applicationJson;
>>>        contentReader: [ :entity | NeoJSONReader fromString: entity contents ];
>>>        get.
>>>
>>> It integrates the JSON parsing step so you get a nice dictionary back. The systemPolicy with the accept makes sure you only do the parsing when application/json comes back. You can also add an #ifFail: block for general error handling should the request fail.
>>>
>>> Sven_______________________________________________
>>> seaside mailing list
>>> [hidden email]
>>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>> _______________________________________________
>> seaside mailing list
>> [hidden email]
>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Sabine Manaa
In reply to this post by Sven Van Caekenberghe-2
ok, with  ConfigurationOfZincHTTPComponents-SvenVanCaekenberghe.49 it works.
Thank you for your help.
Sabine

On Fri, Jun 7, 2013 at 2:17 PM, Sven Van Caekenberghe <[hidden email]> wrote:

> Johan,
>
> On 07 Jun 2013, at 10:11, Johan Brichau <[hidden email]> wrote:
>
>> On 07 Jun 2013, at 10:03, Sven Van Caekenberghe <[hidden email]> wrote:
>>
>>> I am willing to do that (it sounds logical), but can that be done without depending on Seaside itself ? Because that does not sound practical, maybe reducing a circular dependency or at least an interference with the specific Seaside versions and groups that you initially want to load.
>>
>> If I am correct, that should not be a problem.
>>
>> The Seaside30 config can specify to load the 'Zinc-Seaside' version as specified by the Zinc config.
>> All you have to do is list the Zinc-Seaside package in your version methods and make sure that it does not get loaded when not explicitly asking for it.
>> I believe that can be done by not putting it in the #default load group.
>
> I just created ConfigurationOfZincHTTPComponents-SvenVanCaekenberghe.49 which now has a 'Seaside' group that loads the 'Zinc-Seaside' adaptor package with a specific version. It is of course not loaded by default.
>
>> If you want your config to be complete, you can list a dependency on the Seaside project for the Zinc-Seaside package. This would only be loaded if somebody explicitly load the Zinc-Seaside package.
>
> For now I skipped the dependency on Seaside, we'll see how it goes.
>
> Sven
>
>> If that does not work, we need to ask the Metacello doctor ;-)
>>
>> Johan_______________________________________________
>> seaside mailing list
>> [hidden email]
>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
> --
> Sven Van Caekenberghe
> Proudly supporting Pharo
> http://pharo.org
> http://association.pharo.org
> http://consortium.pharo.org
>
>
>
>
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Paul DeBruicker
In reply to this post by Sabine Manaa
You mean why do I ask?  Because I've been using/maintaining it and am
curious about whether anyone ever uses it but me.


Thanks

Paul


On 06/07/2013 05:59 AM, Sabine Knöfel wrote:

> I was using it but then I needed changes as far as I remember.
> Now I have my own solution.
> What is the background of your question?
>
> On Fri, Jun 7, 2013 at 2:39 PM, Paul DeBruicker <[hidden email]> wrote:
>> Are you using the Money library from squeaksource?
>>
>>
>>
>>
>> On Jun 7, 2013, at 2:34 AM, Sabine Knöfel <[hidden email]> wrote:
>>
>>> oh, my first bug ;-)
>>> Thank you for the fast solution!
>>>
>>> On Fri, Jun 7, 2013 at 11:23 AM, Sven Van Caekenberghe <[hidden email]> wrote:
>>>> Sabine,
>>>>
>>>> On 07 Jun 2013, at 10:44, Sabine Knöfel <[hidden email]> wrote:
>>>>
>>>>> Another Point: I use this to get exchange rates from openexchangerates:
>>>>>
>>>>> (ZnClient new
>>>>>              systemPolicy;
>>>>>              http;
>>>>>              host: 'openexchangerates.org'
>>>>>              )
>>>>>                      path: 'api/latest.json?app_id=2ddac6f47cf74936a920beb22ac55704'  ;
>>>>>                      get
>>>>>
>>>>> in 1.4 -> this works fine: {
>>>>> "disclaimer": "E..../",
>>>>> "license": "Data source....se/",
>>>>> "timestamp": 1370592069,
>>>>> "base": "USD",
>>>>> "rates": {
>>>>>   "AED": 3.672719,
>>>>>   "AFN": 54.766067,
>>>>>   "ALL": 106.609251,
>>>>>   "AMD": 418.215,
>>>>> ...
>>>>>
>>>>> in 2.0 -> the result is a byte array. #[123 10 32 32 34 100 105 115 99
>>>>> 108 97 105
>>>>>
>>>>> Do I have to change something here?
>>>>> Sabine
>>>>
>>>> That is indeed a bug. Here is the fix (not yet in any config):
>>>>
>>>> ===
>>>> Name: Zinc-Resource-Meta-Core-SvenVanCaekenberghe.15
>>>> Author: SvenVanCaekenberghe
>>>> Time: 7 June 2013, 11:18:29.493 am
>>>> UUID: b1059f61-d7a1-44b0-bb0a-f558fbbec3c8
>>>> Ancestors: Zinc-Resource-Meta-Core-SvenVanCaekenberghe.14
>>>>
>>>> Fixed a bug in ZnMimeType>>#isBinary (thx Sabine K for reporting this)
>>>> ==
>>>>
>>>> I would write your example as follows:
>>>>
>>>> ZnClient new
>>>>        systemPolicy;
>>>>        http;
>>>>        host: 'openexchangerates.org';
>>>>        path: 'api/latest.json';
>>>>        queryAt: 'app_id' put: '2ddac6f47cf74936a920beb22ac55704';
>>>>        accept: ZnMimeType applicationJson;
>>>>        contentReader: [ :entity | NeoJSONReader fromString: entity contents ];
>>>>        get.
>>>>
>>>> It integrates the JSON parsing step so you get a nice dictionary back. The systemPolicy with the accept makes sure you only do the parsing when application/json comes back. You can also add an #ifFail: block for general error handling should the request fail.
>>>>
>>>> Sven_______________________________________________
>>>> seaside mailing list
>>>> [hidden email]
>>>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>>> _______________________________________________
>>> seaside mailing list
>>> [hidden email]
>>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>> _______________________________________________
>> seaside mailing list
>> [hidden email]
>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Sabine Manaa
Hi Paul,
ok now I understand.
So the answer is: I do not use it.
Greetings
Sabine

On Fri, Jun 7, 2013 at 3:32 PM, Paul DeBruicker <[hidden email]> wrote:

> You mean why do I ask?  Because I've been using/maintaining it and am
> curious about whether anyone ever uses it but me.
>
>
> Thanks
>
> Paul
>
>
> On 06/07/2013 05:59 AM, Sabine Knöfel wrote:
>> I was using it but then I needed changes as far as I remember.
>> Now I have my own solution.
>> What is the background of your question?
>>
>> On Fri, Jun 7, 2013 at 2:39 PM, Paul DeBruicker <[hidden email]> wrote:
>>> Are you using the Money library from squeaksource?
>>>
>>>
>>>
>>>
>>> On Jun 7, 2013, at 2:34 AM, Sabine Knöfel <[hidden email]> wrote:
>>>
>>>> oh, my first bug ;-)
>>>> Thank you for the fast solution!
>>>>
>>>> On Fri, Jun 7, 2013 at 11:23 AM, Sven Van Caekenberghe <[hidden email]> wrote:
>>>>> Sabine,
>>>>>
>>>>> On 07 Jun 2013, at 10:44, Sabine Knöfel <[hidden email]> wrote:
>>>>>
>>>>>> Another Point: I use this to get exchange rates from openexchangerates:
>>>>>>
>>>>>> (ZnClient new
>>>>>>              systemPolicy;
>>>>>>              http;
>>>>>>              host: 'openexchangerates.org'
>>>>>>              )
>>>>>>                      path: 'api/latest.json?app_id=2ddac6f47cf74936a920beb22ac55704'  ;
>>>>>>                      get
>>>>>>
>>>>>> in 1.4 -> this works fine: {
>>>>>> "disclaimer": "E..../",
>>>>>> "license": "Data source....se/",
>>>>>> "timestamp": 1370592069,
>>>>>> "base": "USD",
>>>>>> "rates": {
>>>>>>   "AED": 3.672719,
>>>>>>   "AFN": 54.766067,
>>>>>>   "ALL": 106.609251,
>>>>>>   "AMD": 418.215,
>>>>>> ...
>>>>>>
>>>>>> in 2.0 -> the result is a byte array. #[123 10 32 32 34 100 105 115 99
>>>>>> 108 97 105
>>>>>>
>>>>>> Do I have to change something here?
>>>>>> Sabine
>>>>>
>>>>> That is indeed a bug. Here is the fix (not yet in any config):
>>>>>
>>>>> ===
>>>>> Name: Zinc-Resource-Meta-Core-SvenVanCaekenberghe.15
>>>>> Author: SvenVanCaekenberghe
>>>>> Time: 7 June 2013, 11:18:29.493 am
>>>>> UUID: b1059f61-d7a1-44b0-bb0a-f558fbbec3c8
>>>>> Ancestors: Zinc-Resource-Meta-Core-SvenVanCaekenberghe.14
>>>>>
>>>>> Fixed a bug in ZnMimeType>>#isBinary (thx Sabine K for reporting this)
>>>>> ==
>>>>>
>>>>> I would write your example as follows:
>>>>>
>>>>> ZnClient new
>>>>>        systemPolicy;
>>>>>        http;
>>>>>        host: 'openexchangerates.org';
>>>>>        path: 'api/latest.json';
>>>>>        queryAt: 'app_id' put: '2ddac6f47cf74936a920beb22ac55704';
>>>>>        accept: ZnMimeType applicationJson;
>>>>>        contentReader: [ :entity | NeoJSONReader fromString: entity contents ];
>>>>>        get.
>>>>>
>>>>> It integrates the JSON parsing step so you get a nice dictionary back. The systemPolicy with the accept makes sure you only do the parsing when application/json comes back. You can also add an #ifFail: block for general error handling should the request fail.
>>>>>
>>>>> Sven_______________________________________________
>>>>> seaside mailing list
>>>>> [hidden email]
>>>>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>>>> _______________________________________________
>>>> seaside mailing list
>>>> [hidden email]
>>>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>>> _______________________________________________
>>> seaside mailing list
>>> [hidden email]
>>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>> _______________________________________________
>> seaside mailing list
>> [hidden email]
>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>>
>
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Reply | Threaded
Open this post in threaded view
|

Re: Pharo 2.0 scriptaculous does not work

Johan Brichau-2
In reply to this post by Sven Van Caekenberghe-2
Thanks Sven.

I'm adapting the Seaside config to include that group instead of the Zinc-Seaside package.

On 07 Jun 2013, at 14:17, Sven Van Caekenberghe <[hidden email]> wrote:

> Johan,
>
> On 07 Jun 2013, at 10:11, Johan Brichau <[hidden email]> wrote:
>
>> On 07 Jun 2013, at 10:03, Sven Van Caekenberghe <[hidden email]> wrote:
>>
>>> I am willing to do that (it sounds logical), but can that be done without depending on Seaside itself ? Because that does not sound practical, maybe reducing a circular dependency or at least an interference with the specific Seaside versions and groups that you initially want to load.
>>
>> If I am correct, that should not be a problem.
>>
>> The Seaside30 config can specify to load the 'Zinc-Seaside' version as specified by the Zinc config.
>> All you have to do is list the Zinc-Seaside package in your version methods and make sure that it does not get loaded when not explicitly asking for it.
>> I believe that can be done by not putting it in the #default load group.
>
> I just created ConfigurationOfZincHTTPComponents-SvenVanCaekenberghe.49 which now has a 'Seaside' group that loads the 'Zinc-Seaside' adaptor package with a specific version. It is of course not loaded by default.
>
>> If you want your config to be complete, you can list a dependency on the Seaside project for the Zinc-Seaside package. This would only be loaded if somebody explicitly load the Zinc-Seaside package.
>
> For now I skipped the dependency on Seaside, we'll see how it goes.
>
> Sven
>
>> If that does not work, we need to ask the Metacello doctor ;-)
>>
>> Johan_______________________________________________
>> seaside mailing list
>> [hidden email]
>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
> --
> Sven Van Caekenberghe
> Proudly supporting Pharo
> http://pharo.org
> http://association.pharo.org
> http://consortium.pharo.org
>
>
>
>
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
12