GRPharoPlatform>>isIpAddress bug?

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

GRPharoPlatform>>isIpAddress bug?

Marco A.
Hi,

I think I've discovered an problem in the following class>>method but still considering myself somewhat of a newbie, I'm not entirely sure:

GRPharoPlatform>>isIpAddress: aString
        | ip |
        ip := aString findTokens: '.'.
        ^ ip size = 4
                and: [ ip allSatisfy: [ :each | each greaseInteger notNil
                        and: [ each greaseInteger notNil between: 0 and: 255] ] ]


The problem is the last line "each greaseInteger notNil between: 0 and: 255"... where the notNil message returns a true or false, and it does not respond to "between:and:". I believe the fix ought to be to remove the "notNil" in the last line to result in the line:
         "each greaseInteger between: 0 and: 255"
since the "notNil" is already considered before the "and:".


This is from the most recent One-click download:
        Pharo1.3
        Latest update: #13307

------------------------------------------------------
Marco A. Gonzalez



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

Re: GRPharoPlatform>>isIpAddress bug?

Johan Brichau-2
Hi Marco,

You should update Seaside. This was fixed 6 months ago: http://code.google.com/p/seaside/issues/detail?id=646

Load the most recent ConfigurationOfSeaside30 and execute
ConfigurationOfSeaside30 load

best regards,
Johan

On 20 Sep 2011, at 16:59, Marco A. Gonzalez wrote:

> Hi,
>
> I think I've discovered an problem in the following class>>method but still considering myself somewhat of a newbie, I'm not entirely sure:
>
> GRPharoPlatform>>isIpAddress: aString
> | ip |
> ip := aString findTokens: '.'.
> ^ ip size = 4
> and: [ ip allSatisfy: [ :each | each greaseInteger notNil
> and: [ each greaseInteger notNil between: 0 and: 255] ] ]
>
>
> The problem is the last line "each greaseInteger notNil between: 0 and: 255"... where the notNil message returns a true or false, and it does not respond to "between:and:". I believe the fix ought to be to remove the "notNil" in the last line to result in the line:
> "each greaseInteger between: 0 and: 255"
> since the "notNil" is already considered before the "and:".
>
>
> This is from the most recent One-click download:
> Pharo1.3
> Latest update: #13307
>
> ------------------------------------------------------
> Marco A. Gonzalez
>
>
>
> _______________________________________________
> 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: GRPharoPlatform>>isIpAddress bug?

AA-2
In reply to this post by Marco A.
I sent in this same report just a couple of weeks ago.  It's been fixed in the latest Seaside:

> Updates:
> Status: Duplicate
> Mergedinto: 646
>
> Comment #1 on issue 687 by [hidden email]: Sending emails: error in  
> GRPharoPlatform>>isIpAddress:
> http://code.google.com/p/seaside/issues/detail?id=687
>
> That's a duplicate of Issue 646 and is fixed in Seaside 3.0.4 and newer.

Amir


On Tue, 20 Sep 2011 10:59:14 -0400
"Marco A. Gonzalez" <[hidden email]> wrote:

> Hi,
>
> I think I've discovered an problem in the following class>>method but still considering myself somewhat of a newbie, I'm not entirely sure:
>
> GRPharoPlatform>>isIpAddress: aString
> | ip |
> ip := aString findTokens: '.'.
> ^ ip size = 4
> and: [ ip allSatisfy: [ :each | each greaseInteger notNil
> and: [ each greaseInteger notNil between: 0 and: 255] ] ]
>
>
> The problem is the last line "each greaseInteger notNil between: 0 and: 255"... where the notNil message returns a true or false, and it does not respond to "between:and:". I believe the fix ought to be to remove the "notNil" in the last line to result in the line:
> "each greaseInteger between: 0 and: 255"
> since the "notNil" is already considered before the "and:".
>
>
> This is from the most recent One-click download:
> Pharo1.3
> Latest update: #13307
>
> ------------------------------------------------------
> Marco A. Gonzalez
>
>
>
> _______________________________________________
> 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: GRPharoPlatform>>isIpAddress bug?

Marco A.
In reply to this post by Johan Brichau-2
Johan,

Thanks for the quick response. How do I get the 3.0.6 version or the latest version?

I just downloaded a fresh version of Pharo and executed the following in a Workspace window (while I had a Transcript window open):

seasideLoadTime := Time millisecondsToRun: [
        Gofer new
                squeaksource: 'MetacelloRepository';
                package: 'ConfigurationOfSeaside30';
        load.
       
        ((Smalltalk at: #ConfigurationOfSeaside30) project latestVersion) load.
].

... and the Transcript window showed "... finished 3.0.3.1".

and when I did a "print-it" on "ConfigurationOfSeaside30 project latestVersion", it showed the following:
        >=3.0.3.1 [ConfigurationOfSeaside30]

- Marco A.


On Sep 20, 2011, at 11:09 AM, Johan Brichau wrote:

> Hi Marco,
>
> You should update Seaside. This was fixed 6 months ago: http://code.google.com/p/seaside/issues/detail?id=646
>
> Load the most recent ConfigurationOfSeaside30 and execute
> ConfigurationOfSeaside30 load
>
> best regards,
> Johan
>
> On 20 Sep 2011, at 16:59, Marco A. Gonzalez wrote:
>
>> Hi,
>>
>> I think I've discovered an problem in the following class>>method but still considering myself somewhat of a newbie, I'm not entirely sure:
>>
>> GRPharoPlatform>>isIpAddress: aString
>> | ip |
>> ip := aString findTokens: '.'.
>> ^ ip size = 4
>> and: [ ip allSatisfy: [ :each | each greaseInteger notNil
>> and: [ each greaseInteger notNil between: 0 and: 255] ] ]
>>
>>
>> The problem is the last line "each greaseInteger notNil between: 0 and: 255"... where the notNil message returns a true or false, and it does not respond to "between:and:". I believe the fix ought to be to remove the "notNil" in the last line to result in the line:
>> "each greaseInteger between: 0 and: 255"
>> since the "notNil" is already considered before the "and:".
>>
>>
>> This is from the most recent One-click download:
>> Pharo1.3
>> Latest update: #13307
>>
>> ------------------------------------------------------
>> Marco A. Gonzalez
>>
>>
>>
>> _______________________________________________
>> 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

------------------------------------------------------
Marco A. Gonzalez, President
Amagavi, Inc.
Developer of database-driven web sites

web: http://www.amagavi.com/
email on iPhone: [hidden email]
cell: 202-222-5137




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

Re: GRPharoPlatform>>isIpAddress bug?

Johan Brichau-2
In reply to this post by Johan Brichau-2
Marco,

You should first download the latest configuration of Seaside as well. The one with Pharo probably is not the latest one.
You can find it in the MetacelloRepository on squeaksource.

cheers
Johan

On 20 Sep 2011, at 17:09, Johan Brichau wrote:

> Hi Marco,
>
> You should update Seaside. This was fixed 6 months ago: http://code.google.com/p/seaside/issues/detail?id=646
>
> Load the most recent ConfigurationOfSeaside30 and execute
> ConfigurationOfSeaside30 load
>
> best regards,
> Johan
>
> On 20 Sep 2011, at 16:59, Marco A. Gonzalez wrote:
>
>> Hi,
>>
>> I think I've discovered an problem in the following class>>method but still considering myself somewhat of a newbie, I'm not entirely sure:
>>
>> GRPharoPlatform>>isIpAddress: aString
>> | ip |
>> ip := aString findTokens: '.'.
>> ^ ip size = 4
>> and: [ ip allSatisfy: [ :each | each greaseInteger notNil
>> and: [ each greaseInteger notNil between: 0 and: 255] ] ]
>>
>>
>> The problem is the last line "each greaseInteger notNil between: 0 and: 255"... where the notNil message returns a true or false, and it does not respond to "between:and:". I believe the fix ought to be to remove the "notNil" in the last line to result in the line:
>> "each greaseInteger between: 0 and: 255"
>> since the "notNil" is already considered before the "and:".
>>
>>
>> This is from the most recent One-click download:
>> Pharo1.3
>> Latest update: #13307
>>
>> ------------------------------------------------------
>> Marco A. Gonzalez
>>
>>
>>
>> _______________________________________________
>> 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: GRPharoPlatform>>isIpAddress bug?

Marco A.
Johan,

How do I get the 3.0.6 version or the latest version?

I just downloaded a fresh version of Pharo and executed the following in a Workspace window (while I had a Transcript window open):

seasideLoadTime := Time millisecondsToRun: [
        Gofer new
                squeaksource: 'MetacelloRepository';
                package: 'ConfigurationOfSeaside30';
        load.
       
        ((Smalltalk at: #ConfigurationOfSeaside30) project latestVersion) load.
].

... and the Transcript window showed "... finished 3.0.3.1".

and when I did a "print-it" on "ConfigurationOfSeaside30 project latestVersion", it showed the following:
        >=3.0.3.1 [ConfigurationOfSeaside30]

- Marco A.


On Sep 20, 2011, at 1:39 PM, Johan Brichau wrote:

> Marco,
>
> You should first download the latest configuration of Seaside as well. The one with Pharo probably is not the latest one.
> You can find it in the MetacelloRepository on squeaksource.
>
> cheers
> Johan
>
> On 20 Sep 2011, at 17:09, Johan Brichau wrote:
>
>> Hi Marco,
>>
>> You should update Seaside. This was fixed 6 months ago: http://code.google.com/p/seaside/issues/detail?id=646
>>
>> Load the most recent ConfigurationOfSeaside30 and execute
>> ConfigurationOfSeaside30 load
>>
>> best regards,
>> Johan
>>
>> On 20 Sep 2011, at 16:59, Marco A. Gonzalez wrote:
>>
>>> Hi,
>>>
>>> I think I've discovered an problem in the following class>>method but still considering myself somewhat of a newbie, I'm not entirely sure:
>>>
>>> GRPharoPlatform>>isIpAddress: aString
>>> | ip |
>>> ip := aString findTokens: '.'.
>>> ^ ip size = 4
>>> and: [ ip allSatisfy: [ :each | each greaseInteger notNil
>>> and: [ each greaseInteger notNil between: 0 and: 255] ] ]
>>>
>>>
>>> The problem is the last line "each greaseInteger notNil between: 0 and: 255"... where the notNil message returns a true or false, and it does not respond to "between:and:". I believe the fix ought to be to remove the "notNil" in the last line to result in the line:
>>> "each greaseInteger between: 0 and: 255"
>>> since the "notNil" is already considered before the "and:".
>>>
>>>
>>> This is from the most recent One-click download:
>>> Pharo1.3
>>> Latest update: #13307
>>>
>>> ------------------------------------------------------
>>> Marco A. Gonzalez
>>>
>>>
>>>
>>> _______________________________________________
>>> 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

------------------------------------------------------
Marco A. Gonzalez, President
Amagavi, Inc.
Developer of database-driven web sites

web: http://www.amagavi.com/
email on iPhone: [hidden email]
cell: 202-222-5137




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

Re: GRPharoPlatform>>isIpAddress bug?

Philippe Marschall
In reply to this post by Marco A.
2011/9/20 Marco A. Gonzalez <[hidden email]>:

> Johan,
>
> Thanks for the quick response. How do I get the 3.0.6 version or the latest version?
>
> I just downloaded a fresh version of Pharo and executed the following in a Workspace window (while I had a Transcript window open):
>
> seasideLoadTime := Time millisecondsToRun: [
>        Gofer new
>                squeaksource: 'MetacelloRepository';
>                package: 'ConfigurationOfSeaside30';
>        load.
>
>        ((Smalltalk at: #ConfigurationOfSeaside30) project latestVersion) load.
> ].
>
> ... and the Transcript window showed "... finished 3.0.3.1".
>
> and when I did a "print-it" on "ConfigurationOfSeaside30 project latestVersion", it showed the following:
>        >=3.0.3.1 [ConfigurationOfSeaside30]

Check this thread:

 [1] http://lists.squeakfoundation.org/pipermail/seaside/2011-September/027444.html

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