Hello,
I would suggest to replace the two methods -------------------------------------------------------------- OSPRocess class >> platformName "After Squeak version 3.6, #platformName was moved to SmalltalkImage "
^ ((Smalltalk classNamed: 'SmalltalkImage') ifNil: [^ Smalltalk platformName]) current platformName
OSPRocess class >> osVersion "After Squeak version 3.6, #osVersion was moved to SmalltalkImage " ^ ((Smalltalk classNamed: 'SmalltalkImage') ifNil: [^ Smalltalk osVersion]) current osVersion
-------------------------------------------------------------- by: ------------------------------------------------------------- OSProcess class >> platformName
^ ((Smalltalk classNamed: 'OSPlatform') ifNil: [
(Smalltalk classNamed: 'SmalltalkImage') current ifNil: [^ Smalltalk platformName]]) platformName
OSProcess class >> osVersion ^ ((Smalltalk classNamed: 'OSPlatform')
ifNil: [ (Smalltalk classNamed: 'SmalltalkImage') current ifNil: [^ Smalltalk osVersion]]) osVersion
------------------------------------------------------------ to avoid deprecation messages when using it in Pharo 1.2. Does it looks good? I'm not able to publish on the squeaksource repository
_______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
On Fri, Sep 03, 2010 at 01:03:31PM +0200, Cyrille Delaunay wrote:
> Hello, > > I would suggest to replace the two methods > -------------------------------------------------------------- > OSPRocess class >> platformName > "After Squeak version 3.6, #platformName was moved to SmalltalkImage " > > ^ ((Smalltalk classNamed: 'SmalltalkImage') > ifNil: [^ Smalltalk platformName]) current platformName > > OSPRocess class >> osVersion > "After Squeak version 3.6, #osVersion was moved to SmalltalkImage " > > ^ ((Smalltalk classNamed: 'SmalltalkImage') > ifNil: [^ Smalltalk osVersion]) current osVersion > > -------------------------------------------------------------- > by: > ------------------------------------------------------------- > OSProcess class >> platformName > ^ ((Smalltalk classNamed: 'OSPlatform') > ifNil: [ > (Smalltalk classNamed: 'SmalltalkImage') current > ifNil: [^ Smalltalk platformName]]) platformName > > OSProcess class >> osVersion > ^ ((Smalltalk classNamed: 'OSPlatform') > ifNil: [ > (Smalltalk classNamed: 'SmalltalkImage') current > ifNil: [^ Smalltalk osVersion]]) osVersion > ------------------------------------------------------------ > > to avoid deprecation messages when using it in Pharo 1.2. Does it looks > good? I'm not able to publish on the squeaksource repository This failed on the first Pharo image that I tried, which was a Pharo-1.1-11400-rc2dev10.06.1 image. I think this is the subject of some recent refactoring, so I'm not sure if it's safe to use it yet (will somebody try to load OSProcess in one of the images that has OSPlatform but that does not yet have the #platformName refactoring?). I expect that there are several versions of Pharo in general circulation, so can someone give me some guidance as to whether it is safe to code for "OSPlatform current platformName" as the expected idiom on Pharo, or should we wait a while and live with the deprecation warnings? Thanks, Dave _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
Hi david
I think that you should wait. 1.1 is stable and out. 1.2 is in flux. When 1.2 gets in beta this will be time to settle down things. Cyrille I know why you want 1.2 version else you cannot build a hudson working solution to run top of the edge version. Now I will do the changes suggested by henrik to get a backward compatible version. I suggest to use metacello to control version now I understand that people want to avoid branching now it means that we (the people working on the unstable stream may lack tools but this is ok). Stef On Sep 3, 2010, at 6:30 PM, David T. Lewis wrote: > On Fri, Sep 03, 2010 at 01:03:31PM +0200, Cyrille Delaunay wrote: >> Hello, >> >> I would suggest to replace the two methods >> -------------------------------------------------------------- >> OSPRocess class >> platformName >> "After Squeak version 3.6, #platformName was moved to SmalltalkImage " >> >> ^ ((Smalltalk classNamed: 'SmalltalkImage') >> ifNil: [^ Smalltalk platformName]) current platformName >> >> OSPRocess class >> osVersion >> "After Squeak version 3.6, #osVersion was moved to SmalltalkImage " >> >> ^ ((Smalltalk classNamed: 'SmalltalkImage') >> ifNil: [^ Smalltalk osVersion]) current osVersion >> >> -------------------------------------------------------------- >> by: >> ------------------------------------------------------------- >> OSProcess class >> platformName >> ^ ((Smalltalk classNamed: 'OSPlatform') >> ifNil: [ >> (Smalltalk classNamed: 'SmalltalkImage') current >> ifNil: [^ Smalltalk platformName]]) platformName >> >> OSProcess class >> osVersion >> ^ ((Smalltalk classNamed: 'OSPlatform') >> ifNil: [ >> (Smalltalk classNamed: 'SmalltalkImage') current >> ifNil: [^ Smalltalk osVersion]]) osVersion >> ------------------------------------------------------------ >> >> to avoid deprecation messages when using it in Pharo 1.2. Does it looks >> good? I'm not able to publish on the squeaksource repository > > This failed on the first Pharo image that I tried, which was a > Pharo-1.1-11400-rc2dev10.06.1 image. I think this is the subject > of some recent refactoring, so I'm not sure if it's safe to use > it yet (will somebody try to load OSProcess in one of the images > that has OSPlatform but that does not yet have the #platformName > refactoring?). > > I expect that there are several versions of Pharo in general > circulation, so can someone give me some guidance as to whether > it is safe to code for "OSPlatform current platformName" as the > expected idiom on Pharo, or should we wait a while and live with > the deprecation warnings? > > Thanks, > > Dave > > > _______________________________________________ > Pharo-project mailing list > [hidden email] > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
On Fri, Sep 03, 2010 at 08:57:55PM +0200, St?phane Ducasse wrote:
> Hi david > > I think that you should wait. 1.1 is stable and out. Thanks Stef, good advice, that's what I will do. Dave > 1.2 is in flux. When 1.2 gets in beta this will be time to settle down things. > Cyrille I know why you want 1.2 version else you cannot build a hudson working solution > to run top of the edge version. Now I will do the changes suggested by henrik to get a backward compatible version. > I suggest to use metacello to control version now I understand that people want to avoid branching > now it means that we (the people working on the unstable stream may lack tools but this is ok). > > Stef > > On Sep 3, 2010, at 6:30 PM, David T. Lewis wrote: > > > On Fri, Sep 03, 2010 at 01:03:31PM +0200, Cyrille Delaunay wrote: > >> Hello, > >> > >> I would suggest to replace the two methods > >> -------------------------------------------------------------- > >> OSPRocess class >> platformName > >> "After Squeak version 3.6, #platformName was moved to SmalltalkImage " > >> > >> ^ ((Smalltalk classNamed: 'SmalltalkImage') > >> ifNil: [^ Smalltalk platformName]) current platformName > >> > >> OSPRocess class >> osVersion > >> "After Squeak version 3.6, #osVersion was moved to SmalltalkImage " > >> > >> ^ ((Smalltalk classNamed: 'SmalltalkImage') > >> ifNil: [^ Smalltalk osVersion]) current osVersion > >> > >> -------------------------------------------------------------- > >> by: > >> ------------------------------------------------------------- > >> OSProcess class >> platformName > >> ^ ((Smalltalk classNamed: 'OSPlatform') > >> ifNil: [ > >> (Smalltalk classNamed: 'SmalltalkImage') current > >> ifNil: [^ Smalltalk platformName]]) platformName > >> > >> OSProcess class >> osVersion > >> ^ ((Smalltalk classNamed: 'OSPlatform') > >> ifNil: [ > >> (Smalltalk classNamed: 'SmalltalkImage') current > >> ifNil: [^ Smalltalk osVersion]]) osVersion > >> ------------------------------------------------------------ > >> > >> to avoid deprecation messages when using it in Pharo 1.2. Does it looks > >> good? I'm not able to publish on the squeaksource repository > > > > This failed on the first Pharo image that I tried, which was a > > Pharo-1.1-11400-rc2dev10.06.1 image. I think this is the subject > > of some recent refactoring, so I'm not sure if it's safe to use > > it yet (will somebody try to load OSProcess in one of the images > > that has OSPlatform but that does not yet have the #platformName > > refactoring?). > > > > I expect that there are several versions of Pharo in general > > circulation, so can someone give me some guidance as to whether > > it is safe to code for "OSPlatform current platformName" as the > > expected idiom on Pharo, or should we wait a while and live with > > the deprecation warnings? > > > > Thanks, > > > > Dave > > > > > > _______________________________________________ > > Pharo-project mailing list > > [hidden email] > > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project > > > _______________________________________________ > Pharo-project mailing list > [hidden email] > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
I integrated the undeprecation suggested by henrik
On Sep 3, 2010, at 10:17 PM, David T. Lewis wrote: > On Fri, Sep 03, 2010 at 08:57:55PM +0200, St?phane Ducasse wrote: >> Hi david >> >> I think that you should wait. 1.1 is stable and out. > > Thanks Stef, good advice, that's what I will do. > > Dave > > >> 1.2 is in flux. When 1.2 gets in beta this will be time to settle down things. >> Cyrille I know why you want 1.2 version else you cannot build a hudson working solution >> to run top of the edge version. Now I will do the changes suggested by henrik to get a backward compatible version. >> I suggest to use metacello to control version now I understand that people want to avoid branching >> now it means that we (the people working on the unstable stream may lack tools but this is ok). >> >> Stef >> >> On Sep 3, 2010, at 6:30 PM, David T. Lewis wrote: >> >>> On Fri, Sep 03, 2010 at 01:03:31PM +0200, Cyrille Delaunay wrote: >>>> Hello, >>>> >>>> I would suggest to replace the two methods >>>> -------------------------------------------------------------- >>>> OSPRocess class >> platformName >>>> "After Squeak version 3.6, #platformName was moved to SmalltalkImage " >>>> >>>> ^ ((Smalltalk classNamed: 'SmalltalkImage') >>>> ifNil: [^ Smalltalk platformName]) current platformName >>>> >>>> OSPRocess class >> osVersion >>>> "After Squeak version 3.6, #osVersion was moved to SmalltalkImage " >>>> >>>> ^ ((Smalltalk classNamed: 'SmalltalkImage') >>>> ifNil: [^ Smalltalk osVersion]) current osVersion >>>> >>>> -------------------------------------------------------------- >>>> by: >>>> ------------------------------------------------------------- >>>> OSProcess class >> platformName >>>> ^ ((Smalltalk classNamed: 'OSPlatform') >>>> ifNil: [ >>>> (Smalltalk classNamed: 'SmalltalkImage') current >>>> ifNil: [^ Smalltalk platformName]]) platformName >>>> >>>> OSProcess class >> osVersion >>>> ^ ((Smalltalk classNamed: 'OSPlatform') >>>> ifNil: [ >>>> (Smalltalk classNamed: 'SmalltalkImage') current >>>> ifNil: [^ Smalltalk osVersion]]) osVersion >>>> ------------------------------------------------------------ >>>> >>>> to avoid deprecation messages when using it in Pharo 1.2. Does it looks >>>> good? I'm not able to publish on the squeaksource repository >>> >>> This failed on the first Pharo image that I tried, which was a >>> Pharo-1.1-11400-rc2dev10.06.1 image. I think this is the subject >>> of some recent refactoring, so I'm not sure if it's safe to use >>> it yet (will somebody try to load OSProcess in one of the images >>> that has OSPlatform but that does not yet have the #platformName >>> refactoring?). >>> >>> I expect that there are several versions of Pharo in general >>> circulation, so can someone give me some guidance as to whether >>> it is safe to code for "OSPlatform current platformName" as the >>> expected idiom on Pharo, or should we wait a while and live with >>> the deprecation warnings? >>> >>> Thanks, >>> >>> Dave >>> >>> >>> _______________________________________________ >>> Pharo-project mailing list >>> [hidden email] >>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project >> >> >> _______________________________________________ >> Pharo-project mailing list >> [hidden email] >> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project > > _______________________________________________ > Pharo-project mailing list > [hidden email] > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project _______________________________________________ Pharo-project mailing list [hidden email] http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
In reply to this post by David T. Lewis
To follow up on this, I have now updated both OSProcess and CommandShell
to work on Pharo 1.2. I have not yet had a chance to look at the Metacello configurations, but loading the latest versions of OSProcess and CommandShell, and CommandShellPharo from SqueakSource will give the correct configurations. For CommandShell, ignore the MVC warnings on load, or you can load the individual sub-packages from SqueakSource and leave out CommandShell-MVC. The separate CommandShellPharo package in SqS/CommandShell provides world menu registration for opening a command shell morph on Pharo (open a new command shell morph with world -> Tools -> Command shell). This is in its own package because of the use of pragmas for menu registration, which cannot be loaded into some other Squeak images (e.g. Squeak 3.8 and earlier). I note that on Pharo: TextStyle named: 'DefaultFixedTextStyle' ==> a TextStyle Accuny12(FontSet) Which seems to be a proportional font rather than fixed, so the font in a CommandShell window is not as nice as it should be. OSProcess and CommandShell test suites are green on Squeak/Unix VM, but a bit flakey when I run them on Pharo. Issues are timing related, and I cannot say if they are issues in Pharo, CommandShell, or maybe just the way I wrote the tests. But for general use, everything seems to be working now. When running on Cog, you should expect #forkSqueak to fail, but it will no longer crash the VM as in earlier OSProcess versions. However, #forkSqueak is used extensively in the unit tests for various multiprocessing test setups, which means that the test suites will not run properly. That said, most of the rest of OSProcess and CommandShell should work on Cog. Most things should work on a Mac VM, although I cannot personally verify. Windows support is incomplete and the plugin is not widely available. Dave On Fri, Sep 03, 2010 at 04:17:05PM -0400, David T. Lewis wrote: > On Fri, Sep 03, 2010 at 08:57:55PM +0200, St?phane Ducasse wrote: > > Hi david > > > > I think that you should wait. 1.1 is stable and out. > > Thanks Stef, good advice, that's what I will do. > > Dave > > > > 1.2 is in flux. When 1.2 gets in beta this will be time to settle down things. > > Cyrille I know why you want 1.2 version else you cannot build a hudson working solution > > to run top of the edge version. Now I will do the changes suggested by henrik to get a backward compatible version. > > I suggest to use metacello to control version now I understand that people want to avoid branching > > now it means that we (the people working on the unstable stream may lack tools but this is ok). > > > > Stef > > > > On Sep 3, 2010, at 6:30 PM, David T. Lewis wrote: > > > > > On Fri, Sep 03, 2010 at 01:03:31PM +0200, Cyrille Delaunay wrote: > > >> Hello, > > >> > > >> I would suggest to replace the two methods > > >> -------------------------------------------------------------- > > >> OSPRocess class >> platformName > > >> "After Squeak version 3.6, #platformName was moved to SmalltalkImage " > > >> > > >> ^ ((Smalltalk classNamed: 'SmalltalkImage') > > >> ifNil: [^ Smalltalk platformName]) current platformName > > >> > > >> OSPRocess class >> osVersion > > >> "After Squeak version 3.6, #osVersion was moved to SmalltalkImage " > > >> > > >> ^ ((Smalltalk classNamed: 'SmalltalkImage') > > >> ifNil: [^ Smalltalk osVersion]) current osVersion > > >> > > >> -------------------------------------------------------------- > > >> by: > > >> ------------------------------------------------------------- > > >> OSProcess class >> platformName > > >> ^ ((Smalltalk classNamed: 'OSPlatform') > > >> ifNil: [ > > >> (Smalltalk classNamed: 'SmalltalkImage') current > > >> ifNil: [^ Smalltalk platformName]]) platformName > > >> > > >> OSProcess class >> osVersion > > >> ^ ((Smalltalk classNamed: 'OSPlatform') > > >> ifNil: [ > > >> (Smalltalk classNamed: 'SmalltalkImage') current > > >> ifNil: [^ Smalltalk osVersion]]) osVersion > > >> ------------------------------------------------------------ > > >> > > >> to avoid deprecation messages when using it in Pharo 1.2. Does it looks > > >> good? I'm not able to publish on the squeaksource repository > > > > > > This failed on the first Pharo image that I tried, which was a > > > Pharo-1.1-11400-rc2dev10.06.1 image. I think this is the subject > > > of some recent refactoring, so I'm not sure if it's safe to use > > > it yet (will somebody try to load OSProcess in one of the images > > > that has OSPlatform but that does not yet have the #platformName > > > refactoring?). > > > > > > I expect that there are several versions of Pharo in general > > > circulation, so can someone give me some guidance as to whether > > > it is safe to code for "OSPlatform current platformName" as the > > > expected idiom on Pharo, or should we wait a while and live with > > > the deprecation warnings? > > > > > > Thanks, > > > > > > Dave > > > > > > > > > _______________________________________________ > > > Pharo-project mailing list > > > [hidden email] > > > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project > > > > > > _______________________________________________ > > Pharo-project mailing list > > [hidden email] > > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project > > _______________________________________________ > Pharo-project mailing list > [hidden email] > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project |
Dave,
Does that mean that PipeableOSProcess can load w/o MVC support? That would be great! You've just reminded me that there is a Windows plugin - for a long time, I thought it was necessary to use ProcessWrapper there. I don't have much need for piping on Windows, but one never knows when it might surface again. Is there a binary for the plugin? I find the Linux VM wanting in diagnostic feedback, so I end up hacking and building it from source, but the Windows VM seems to just work as-is; I have not needed to build it for a long time. In fairness, I don't ask much of Windows these days, but I do need to target it. Bill ________________________________________ From: [hidden email] [[hidden email]] On Behalf Of David T. Lewis [[hidden email]] Sent: Tuesday, November 30, 2010 9:44 PM To: [hidden email] Subject: [Pharo-project] OSProcess update (was: [OSProcess] Proposal for Pharo 1.2 compatibility) To follow up on this, I have now updated both OSProcess and CommandShell to work on Pharo 1.2. I have not yet had a chance to look at the Metacello configurations, but loading the latest versions of OSProcess and CommandShell, and CommandShellPharo from SqueakSource will give the correct configurations. For CommandShell, ignore the MVC warnings on load, or you can load the individual sub-packages from SqueakSource and leave out CommandShell-MVC. The separate CommandShellPharo package in SqS/CommandShell provides world menu registration for opening a command shell morph on Pharo (open a new command shell morph with world -> Tools -> Command shell). This is in its own package because of the use of pragmas for menu registration, which cannot be loaded into some other Squeak images (e.g. Squeak 3.8 and earlier). I note that on Pharo: TextStyle named: 'DefaultFixedTextStyle' ==> a TextStyle Accuny12(FontSet) Which seems to be a proportional font rather than fixed, so the font in a CommandShell window is not as nice as it should be. OSProcess and CommandShell test suites are green on Squeak/Unix VM, but a bit flakey when I run them on Pharo. Issues are timing related, and I cannot say if they are issues in Pharo, CommandShell, or maybe just the way I wrote the tests. But for general use, everything seems to be working now. When running on Cog, you should expect #forkSqueak to fail, but it will no longer crash the VM as in earlier OSProcess versions. However, #forkSqueak is used extensively in the unit tests for various multiprocessing test setups, which means that the test suites will not run properly. That said, most of the rest of OSProcess and CommandShell should work on Cog. Most things should work on a Mac VM, although I cannot personally verify. Windows support is incomplete and the plugin is not widely available. Dave |
On Tue, Nov 30, 2010 at 11:24:38PM -0500, Schwab,Wilhelm K wrote:
> Dave, > > Does that mean that PipeableOSProcess can load w/o MVC support? That would be great! Yes. The SqS/CommandShell package is split into sub-packages, so you do not need to load CommandShell-MVC if you do not want it. As always, for Squeak images the easiest thing is to just load the latest version of the full OSProcess and CommandShell packages, which are always up to date for Squeak trunk. On Pharo, you may want to skip the MVC package and also load CommandShellPharo if you want menu registration, but otherwise they are the same. The only new information of interest for Squeak is that folks running Cog on Linux should update their OSProcess to the latest version, otherwise OSProcess can crash the VM with X11 protocol errors when attempting a #forkSqueak. > > You've just reminded me that there is a Windows plugin - for a long time, I thought it was necessary to use ProcessWrapper there. I don't have much need for piping on Windows, but one never knows when it might surface again. Is there a binary for the plugin? I find the Linux VM wanting in diagnostic feedback, so I end up hacking and building it from source, but the Windows VM seems to just work as-is; I have not needed to build it for a long time. In fairness, I don't ask much of Windows these days, but I do need to target it. > > Bill > I think that ProcessWrapper is the best way to go for Windows right now. Dave > > > ________________________________________ > From: [hidden email] [[hidden email]] On Behalf Of David T. Lewis [[hidden email]] > Sent: Tuesday, November 30, 2010 9:44 PM > To: [hidden email] > Subject: [Pharo-project] OSProcess update (was: [OSProcess] Proposal for Pharo 1.2 compatibility) > > To follow up on this, I have now updated both OSProcess and CommandShell > to work on Pharo 1.2. I have not yet had a chance to look at the > Metacello configurations, but loading the latest versions of OSProcess > and CommandShell, and CommandShellPharo from SqueakSource will give > the correct configurations. For CommandShell, ignore the MVC warnings > on load, or you can load the individual sub-packages from SqueakSource > and leave out CommandShell-MVC. > > The separate CommandShellPharo package in SqS/CommandShell provides > world menu registration for opening a command shell morph on Pharo > (open a new command shell morph with world -> Tools -> Command shell). > This is in its own package because of the use of pragmas for menu > registration, which cannot be loaded into some other Squeak images > (e.g. Squeak 3.8 and earlier). > > I note that on Pharo: > TextStyle named: 'DefaultFixedTextStyle' ==> a TextStyle Accuny12(FontSet) > Which seems to be a proportional font rather than fixed, so the font > in a CommandShell window is not as nice as it should be. > > OSProcess and CommandShell test suites are green on Squeak/Unix VM, > but a bit flakey when I run them on Pharo. Issues are timing related, > and I cannot say if they are issues in Pharo, CommandShell, or maybe > just the way I wrote the tests. But for general use, everything seems > to be working now. > > When running on Cog, you should expect #forkSqueak to fail, but it > will no longer crash the VM as in earlier OSProcess versions. However, > #forkSqueak is used extensively in the unit tests for various > multiprocessing test setups, which means that the test suites will > not run properly. That said, most of the rest of OSProcess and > CommandShell should work on Cog. > > Most things should work on a Mac VM, although I cannot personally > verify. Windows support is incomplete and the plugin is not widely > available. > > Dave > |
Free forum by Nabble | Edit this page |