Can't load OSProcess in last Pharo Core 1.3

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

Can't load OSProcess in last Pharo Core 1.3

Adrien BARREAU
Hi all,

I just tried to load OSProcess in the last PharoCore 1.3 (I took it from hudson). It fails when it tries to add ThisOSProcess to the startup list with:
    Smalltalk addToStartUpList: ThisOSProcess after: ImageSegment.
in ThisOSProcess class>>initialize.


It seems that ImageSegment is not in the StartUpList anymore.
Is that normal?

Adrien.
Reply | Threaded
Open this post in threaded view
|

Re: Can't load OSProcess in last Pharo Core 1.3

Adrien BARREAU
I just saw that update 13205 removed ImageSegment from the StartUpList.

Replacing
    Smalltalk addToStartUpList: ThisOSProcess after: ImageSegment.
by
    Smalltalk addToStartUpList: ThisOSProcess before: UUIDGenerator.
in ThisOSProcess>>initialize would be ok I think (and would have the same result).

Adrien.
   


From: [hidden email]
To: [hidden email]
Date: Fri, 20 May 2011 17:07:04 +0200
Subject: [Pharo-project] Can't load OSProcess in last Pharo Core 1.3

Hi all,

I just tried to load OSProcess in the last PharoCore 1.3 (I took it from hudson). It fails when it tries to add ThisOSProcess to the startup list with:
    Smalltalk addToStartUpList: ThisOSProcess after: ImageSegment.
in ThisOSProcess class>>initialize.


It seems that ImageSegment is not in the StartUpList anymore.
Is that normal?

Adrien.
Reply | Threaded
Open this post in threaded view
|

Re: Can't load OSProcess in last Pharo Core 1.3

Marcus Denker-4
In reply to this post by Adrien BARREAU

On May 20, 2011, at 5:30 PM, Adrien BARREAU wrote:

> I just saw that update 13205 removed ImageSegment from the StartUpList.
>
> Replacing
>     Smalltalk addToStartUpList: ThisOSProcess after: ImageSegment.
> by
>     Smalltalk addToStartUpList: ThisOSProcess before: UUIDGenerator.
> in ThisOSProcess>>initialize would be ok I think (and would have the same result).
>
>
The problem is that there was no #addToStartUpList:before:
So if you wanted to add yourself before something (because that thing depends on you),
you had to add after something completely unrelated, leading to strange dependencies
(like OSProcess depending on ImageSegment in the startup list..)

        Marcus



--
Marcus Denker  -- http://www.marcusdenker.de
INRIA Lille -- Nord Europe. Team RMoD.


Reply | Threaded
Open this post in threaded view
|

Re: Can't load OSProcess in last Pharo Core 1.3

Miguel Cobá
In reply to this post by Adrien BARREAU
Yes that is a workaround but not a final fix, because it depends on a
specific class in the system.
In squeak, IIRC, it was a discussion about changing ordering of startup
items using numbers instead of names of classes in the image, something
similiar to the Linux startup infrastructure.

But for now it is ok to change it as you said.

Cheers

El vie, 20-05-2011 a las 17:29 +0200, Adrien BARREAU escribió:

> I just saw that update 13205 removed ImageSegment from the
> StartUpList.
>
> Replacing
>     Smalltalk addToStartUpList: ThisOSProcess after: ImageSegment.
> by
>     Smalltalk addToStartUpList: ThisOSProcess before: UUIDGenerator.
> in ThisOSProcess>>initialize would be ok I think (and would have the
> same result).
>
> Adrien.
>    
>
>
> ______________________________________________________________________
> From: [hidden email]
> To: [hidden email]
> Date: Fri, 20 May 2011 17:07:04 +0200
> Subject: [Pharo-project] Can't load OSProcess in last Pharo Core 1.3
>
> Hi all,
>
> I just tried to load OSProcess in the last PharoCore 1.3 (I took it
> from hudson). It fails when it tries to add ThisOSProcess to the
> startup list with:
>     Smalltalk addToStartUpList: ThisOSProcess after: ImageSegment.
> in ThisOSProcess class>>initialize.
>
>
> It seems that ImageSegment is not in the StartUpList anymore.
> Is that normal?
>
> Adrien.

--
Miguel Cobá
http://twitter.com/MiguelCobaMtz
http://miguel.leugim.com.mx




Reply | Threaded
Open this post in threaded view
|

Re: Can't load OSProcess in last Pharo Core 1.3

Mariano Martinez Peck
In reply to this post by Adrien BARREAU


On Fri, May 20, 2011 at 5:07 PM, Adrien BARREAU <[hidden email]> wrote:
Hi all,

I just tried to load OSProcess in the last PharoCore 1.3 (I took it from hudson). It fails when it tries to add ThisOSProcess to the startup list with:
    Smalltalk addToStartUpList: ThisOSProcess after: ImageSegment.

I think that is incorrect. Why would OSProcess requires to be before ImageSegment?
OSProcess should be before what it really needs. And if it doesn't need anything then just use #addToStartupList:
 
in ThisOSProcess class>>initialize.


It seems that ImageSegment is not in the StartUpList anymore.
Is that normal?

Adrien.



--
Mariano
http://marianopeck.wordpress.com

Reply | Threaded
Open this post in threaded view
|

Re: Can't load OSProcess in last Pharo Core 1.3

Stéphane Ducasse
In reply to this post by Adrien BARREAU
Adrien

people do not realize that you are not maintaining OSProcess :)
So we should check and publish a new version of OSProcess with a difference startUpDependency.

On May 20, 2011, at 5:07 PM, Adrien BARREAU wrote:

> Hi all,
>
> I just tried to load OSProcess in the last PharoCore 1.3 (I took it from hudson). It fails when it tries to add ThisOSProcess to the startup list with:
>     Smalltalk addToStartUpList: ThisOSProcess after: ImageSegment.
> in ThisOSProcess class>>initialize.
>
>
> It seems that ImageSegment is not in the StartUpList anymore.
> Is that normal?
>
> Adrien.


Reply | Threaded
Open this post in threaded view
|

Re: Can't load OSProcess in last Pharo Core 1.3

David T. Lewis
I don't remember why I put that dependency on the startup list for
OSProcess, but I'll take a look at it this weekend and see if there
is a better way. Probably it was just to ensure that file related
things were initialized prior to starting OSProcess initialization.

Dave

On Fri, May 20, 2011 at 08:26:59PM +0200, St?phane Ducasse wrote:

> Adrien
>
> people do not realize that you are not maintaining OSProcess :)
> So we should check and publish a new version of OSProcess with a difference startUpDependency.
>
> On May 20, 2011, at 5:07 PM, Adrien BARREAU wrote:
>
> > Hi all,
> >
> > I just tried to load OSProcess in the last PharoCore 1.3 (I took it from hudson). It fails when it tries to add ThisOSProcess to the startup list with:
> >     Smalltalk addToStartUpList: ThisOSProcess after: ImageSegment.
> > in ThisOSProcess class>>initialize.
> >
> >
> > It seems that ImageSegment is not in the StartUpList anymore.
> > Is that normal?
> >
> > Adrien.
>

Reply | Threaded
Open this post in threaded view
|

Re: Can't load OSProcess in last Pharo Core 1.3

Stéphane Ducasse
thanks david

Stef
s
On May 20, 2011, at 9:18 PM, David T. Lewis wrote:

> I don't remember why I put that dependency on the startup list for
> OSProcess, but I'll take a look at it this weekend and see if there
> is a better way. Probably it was just to ensure that file related
> things were initialized prior to starting OSProcess initialization.
>
> Dave
>
> On Fri, May 20, 2011 at 08:26:59PM +0200, St?phane Ducasse wrote:
>> Adrien
>>
>> people do not realize that you are not maintaining OSProcess :)
>> So we should check and publish a new version of OSProcess with a difference startUpDependency.
>>
>> On May 20, 2011, at 5:07 PM, Adrien BARREAU wrote:
>>
>>> Hi all,
>>>
>>> I just tried to load OSProcess in the last PharoCore 1.3 (I took it from hudson). It fails when it tries to add ThisOSProcess to the startup list with:
>>>    Smalltalk addToStartUpList: ThisOSProcess after: ImageSegment.
>>> in ThisOSProcess class>>initialize.
>>>
>>>
>>> It seems that ImageSegment is not in the StartUpList anymore.
>>> Is that normal?
>>>
>>> Adrien.
>>
>


Reply | Threaded
Open this post in threaded view
|

Re: Can't load OSProcess in last Pharo Core 1.3

David T. Lewis
In reply to this post by David T. Lewis
This is fixed in both OSProcess and CommandShell on SqueakSource.

I found an old comment in my code that says this:

  "Some images may have a bug in startup list processing. Add this
   class to a known place in the middle of the list to avoid getting
   bitten by the bug."

So I knew that it was safe now to just use #addToStartUpList: instead
of #addToStartUpList:after:

This is the reason that people like me with bad memories need to write
good comments ;-)

Dave

On Fri, May 20, 2011 at 03:18:53PM -0400, David T. Lewis wrote:

> I don't remember why I put that dependency on the startup list for
> OSProcess, but I'll take a look at it this weekend and see if there
> is a better way. Probably it was just to ensure that file related
> things were initialized prior to starting OSProcess initialization.
>
> Dave
>
> On Fri, May 20, 2011 at 08:26:59PM +0200, St?phane Ducasse wrote:
> > Adrien
> >
> > people do not realize that you are not maintaining OSProcess :)
> > So we should check and publish a new version of OSProcess with a difference startUpDependency.
> >
> > On May 20, 2011, at 5:07 PM, Adrien BARREAU wrote:
> >
> > > Hi all,
> > >
> > > I just tried to load OSProcess in the last PharoCore 1.3 (I took it from hudson). It fails when it tries to add ThisOSProcess to the startup list with:
> > >     Smalltalk addToStartUpList: ThisOSProcess after: ImageSegment.
> > > in ThisOSProcess class>>initialize.
> > >
> > >
> > > It seems that ImageSegment is not in the StartUpList anymore.
> > > Is that normal?
> > >
> > > Adrien.
> >