[Pharo-project] changes with announcements ?

Igor Stasenko siguctua at gmail.com
Fri May 27 12:45:15 CEST 2011

On 27 May 2011 12:05, Cyrille Delaunay <cy.delaunay at gmail.com> wrote:
> Hello,
> Today I experimented some strange behaviours with announcements that I
> didn't have in some previous moose images (moose in now based on Pharo
> 1.3).
> I think that there was some changes related to announcements in pharo
> recently, but I could not be sure it is related.
> At one point in my code I have:
> browser on: AnnouncementClass send: #actionSelector
> browser announce: anAnnouncementClass.
> ....
> ....
> The behaviour I have is like if #actionSelector was executed asynchronously
> from the rest of the code below 'browser announce: ...' .
> Not sure but there is maybe something with exception signals. If any signal
> is emited in #actionSelector it will not execute the rest of the method.
> I was at least able to write a test that do not pass in latest pharo 1.3
> Gofer new
> squeaksource: 'DelaunayTmpStuffs';
> package: 'ExampleAnnouncementProblems';
> load.

It was because on:fork: cuts the stack.
If you signaling exception in your code, you should handle it before
leaving your #actionSelector method.
Otherwise you may put the rest recipients of announcement in danger
and that's why there #on:fork: to prevent that.

Best regards,
Igor Stasenko AKA sig.

More information about the Pharo-project mailing list