Annoying reproducible bug in 3.8-6665

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

Annoying reproducible bug in 3.8-6665

Tim Johnson-6
Hi,

There is an annoying bug I've been running into on the 3.8-6665 image.  It
is totally reproducible from a stock image.

1)  Open the image, elect not to do updates.
2)  Open a workspace.
3)  doIt:  Smalltalk at: myForm put: nil
4)  doIt:  myForm _ Form extent: 100@100.
5)  Open a Browser.
6)  Middle-click in leftmost (class category) pane, search for class Form.
7)  Left-click on any category in the method category pane.
8)  BOOM!  MessageNotUnderstood: UndefinedObject>>beginsWith:

Seems to be something to do with _ to := conversion and the
SystemDictionary.  Maybe I'm doing something wrong that is making the
system flake out, but I don't think so...?

(testing platform Mac PPC 3.8.6Beta6 VM under OS 10.3.9)

Thanks,
Tim J.


Reply | Threaded
Open this post in threaded view
|

Re: Annoying reproducible bug in 3.8-6665

Bert Freudenberg-3
Am 22.06.2006 um 18:27 schrieb [hidden email]:

> Hi,
>
> There is an annoying bug I've been running into on the 3.8-6665  
> image.  It
> is totally reproducible from a stock image.
>
> 1)  Open the image, elect not to do updates.
> 2)  Open a workspace.
> 3)  doIt:  Smalltalk at: myForm put: nil
> 4)  doIt:  myForm _ Form extent: 100@100.
> 5)  Open a Browser.
> 6)  Middle-click in leftmost (class category) pane, search for  
> class Form.
> 7)  Left-click on any category in the method category pane.
> 8)  BOOM!  MessageNotUnderstood: UndefinedObject>>beginsWith:
>
> Seems to be something to do with _ to := conversion and the
> SystemDictionary.  Maybe I'm doing something wrong that is making the
> system flake out, but I don't think so...?

Not a bug. You are putting nil as key into Smalltalk, which is simply  
a Bad Thing To Do. Stop doing that. Smalltalk keys must be *Symbols*.  
They should be uppercase, too:

        Smalltalk at: #MyForm put: nil

To fix your image, do

        Smalltalk removeKey: nil.

- Bert -


Reply | Threaded
Open this post in threaded view
|

Re: Annoying reproducible bug in 3.8-6665

Tim Johnson-6

On Jun 22, 2006, at 12:28 PM, Bert Freudenberg wrote:

> Not a bug. You are putting nil as key into Smalltalk, which is simply
> a Bad Thing To Do. Stop doing that. Smalltalk keys must be *Symbols*.
> They should be uppercase, too:
>
> Smalltalk at: #MyForm put: nil
>
> To fix your image, do
>
> Smalltalk removeKey: nil.

I am a moron!

Thank you very, very much!

*walks away with tail between legs*

- Tim


Reply | Threaded
Open this post in threaded view
|

Re: Annoying reproducible bug in 3.8-6665

stéphane ducasse-2
In reply to this post by Tim Johnson-6
Avoid to use global variable.
If you write code like Smalltalk at: mlkjljlk put: lkjjlj

there is something strange with your design.

Stef

> Hi,
>
> There is an annoying bug I've been running into on the 3.8-6665  
> image.  It
> is totally reproducible from a stock image.
>
> 1)  Open the image, elect not to do updates.
> 2)  Open a workspace.
> 3)  doIt:  Smalltalk at: myForm put: nil
> 4)  doIt:  myForm _ Form extent: 100@100.
> 5)  Open a Browser.
> 6)  Middle-click in leftmost (class category) pane, search for  
> class Form.
> 7)  Left-click on any category in the method category pane.
> 8)  BOOM!  MessageNotUnderstood: UndefinedObject>>beginsWith:
>
> Seems to be something to do with _ to := conversion and the
> SystemDictionary.  Maybe I'm doing something wrong that is making the
> system flake out, but I don't think so...?
>
> (testing platform Mac PPC 3.8.6Beta6 VM under OS 10.3.9)
>
> Thanks,
> Tim J.
>
>


Reply | Threaded
Open this post in threaded view
|

Re: Annoying reproducible bug in 3.8-6665

Tim Johnson-6

On Jun 26, 2006, at 3:52 PM, stéphane ducasse wrote:

> Avoid to use global variable.
> If you write code like Smalltalk at: mlkjljlk put: lkjjlj
>
> there is something strange with your design.

I only do that when I am writing test code in a Workspace.  I am trying
to get in the habit of doing all test code in a class, though :)

Thanks,
Tim