Pharo-dev
By thread
pharo-dev@lists.pharo.org
By month
Messages by month
- ----- 2026 -----
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- 1 participants
- 144619 messages
Re: [Pharo-dev] why we removed debugTest from nautilus?
by Max Leske
For a little more context: the issue was originally raised by Clara in the thread titled "MNU: receiver of "stepToCallee:" is nilâ. IIRC the issue was easily reproducible when debugging a test, then closing the debugger (via the close icon). Clicking âProceedâ on the other hand gracefully terminated the process.
Cheers,
Max
> On 10 Apr 2015, at 09:56, Nicolai Hess <nicolaihess(a)web.de> wrote:
>
> 2015-04-10 2:37 GMT+02:00 Clément Bera <bera.clement(a)gmail.com <mailto:bera.clement@gmail.com>>:
> I was using it frequently too and I have never experienced any issues...
>
> Ok, can you describe a use case, what test case you can start and
> close the debugger without image freeze?
>
> Maybe we can find what is the difference between that
> test case and those that freeze the image, and than find a fix.
>
>
> 2015-04-09 14:58 GMT-07:00 Nicolai Hess <nicolaihess(a)web.de <mailto:nicolaihess@web.de>>:
>
>
> 2015-04-09 23:38 GMT+02:00 phil(a)highoctane.be <mailto:phil@highoctane.be> <phil(a)highoctane.be <mailto:phil@highoctane.be>>:
> No Debug Tests?
>
> Geez, I am using that all the time.
>
> And you're never encountered this issue 14689 <https://pharo.fogbugz.com/default.asp?14689>?
> Or did this work in older versions?
>
>
>
>
> Phil
>
>
> On Thu, Apr 9, 2015 at 10:21 PM, Marcus Denker <marcus.denker(a)inria.fr <mailto:marcus.denker@inria.fr>> wrote:
>
> > On 09 Apr 2015, at 22:32, Sean P. DeNigris <sean(a)clipperadams.com <mailto:sean@clipperadams.com>> wrote:
> >
> > Nicolai Hess wrote
> >> http://forum.world.st/do-we-need-to-debug-testmethods-from-within-Nautilus-… <http://forum.world.st/do-we-need-to-debug-testmethods-from-within-Nautilus-…>
> >
> > Ah, I miss that too! From that thread, it seems it was removed temporarily
> > until we have real breakpoints. Is there an issue for its return?
> >
>
> Not yet.
>
> Marcus
>
>
>
>
April 10, 2015
Re: [Pharo-dev] Problem with asClass usage
by Christophe Demarey
Le 10 avr. 2015 à 06:09, Ben Coman a écrit :
> I believe #asClass itself was introduced for a use case to simplify Workspace "user interactive" Gofer scripts to retrieve and load Configurations. Since this is through away code its not covered by your modularity concerns, and I'm not sure if it came before or after its friends, but can we retain or substitute something to avoid needing ugly "(Smalltalk at: #ConfigurationOfXXX) load" ?
>
> This is a "first impression" consideration for people dealing with Configurations for the first time (even thought we now have Configuration Browser). The use case is that newbies will copy-paste a script from a web site to Playground and execute the whole script resulting in a error "Unknown class ConfigurationOfXXX." They don't know to execute in two separate steps, first "Gofer ... load" then "ConfigurationOfXXX load".
>
> Alternatively, what if the Metacello package extended Gofer with a method #configurationOf: so websites can show...
>
> config :=
> Gofer new
> url: 'http://smalltalkhub.com/mc/MyProject/main'
> package: 'MyXXXPackage';
> load;
> configurationOf: 'XXX' "return class ConfigurationOfXXX"
> config load.
>
> ...so the compiler is dealing with a variable "config" rather than class 'ConfigurationOfXXX' that it doesn't know yet, or a further altenative...
>
> Gofer new
> url: 'http://smalltalkhub.com/mc/MyProject/main'
> package: 'MyXXXPackage';
> load;
> configurationOf: 'XXX' do: [ :config | config load ];
> configurationOf: 'YYY' do: [ :config | config load ].
>
> cheers -ben
It is not a problem anymore.
We have better ways to load a configuration and the associated packages:
Metacello new
configuration: 'XXX';
squeaksource3: 'MyProject';
version: '0.9.0';
load.
Le 10 avr. 2015 à 08:57, phil(a)highoctane.be a écrit :
> For the GLM things, I guess it allows one to have code that works only if an extra module is loaded.
>
> We have asString and it is fine. Now asClass will not be. Duh?
>
> aThing perform: #someAction is as complicated.
>
> Yeah make a lint rule but do not disallow the usage.
>
The problem is that if you want to allow to browse remote code or to have 2 versions of the same class in the system for example, aSymbol asClass will not work. It will always search the class in the environment of the String class. The resolution of a symbol should be the responsibility of Environment.
asString does not have the same problem.
To me, #perform: is not a problem because the resolution of the selector is done by the class. I don't see a case where you do not want that.
Christophe.
> On 10/04/2015 4:32 am, "stepharo" <stepharo(a)free.fr> wrote:
> Hi
>
> We want to raise a strong warning against the extension of the use of asClass and friends.
> asClass should not be used in Pharo distribution. I will propose to deprecate it.
>
> We are working on dependency analysis, module system, remote debugging and asClass introduces
> lose class references and many related problems.
>
> I would like to remove this behavior because it is clear that it will just grow up and lead to deadcode and ugly dependencies.
>
> First, most of the time you can avoid to query Smalltalk globals at: and that BY CONSTRUCTION a software system should be built and it should define its own customization.
>
>
> Second, at least use self class environment at: #foo
>
> Why is it much much much better? because it does not rely on String class resolution and as such
> is much more modular. You do not want to have the resolution of a symbol related to the place where String is defined but on where your code is actually.
>
> Imagine that tomorrow your code is in its own module. Then you want to know from your code point of you
> if a binding exist not from the one of environment in which String is.
>
>
>
>
> here are some examples:
>
> ==============================
> quadrangleClass
> ^ 'QuadrangleForTesting' asClass
>
> Strange it simply breaks. Of course it broke the smallLint rule.
>
> ==============================
> Metacello should better define OSProcess as a dependent.Because it is not clear what will happen
> if if not there?
>
> extractRepositoryFrom: zipFile to: directory
> "unzip <zipFile> into <directory>"
>
> | out err proc errorMessage |
> out := FileStream forceNewFileNamed: '/tmp/zip.out'.
> err := FileStream forceNewFileNamed: '/tmp/zip.err'.
> errorMessage := ''.
> [
> proc := #OSProcess asClass thisOSProcess
> forkJob: '/usr/bin/unzip'
> arguments:
> {'-u'.
> zipFile.
> '-d'.
> directory}
> environment: nil
> descriptors: (Array with: nil with: out with: err).
>
> ==================
>
> I do not get why we need this funky logic.
>
> openInBrickWindowLabeled: aLabel
>
> #GLMSystemWindowBrick asClassIfAbsent: [
> ^ self asMorph openInWindow ].
>
> ^ #GLMSystemWindowBrick asClass new
> label: aLabel;
> color: Color transparent;
> addBrickBack: (
> GLMBrick new
> vSpaceFill
>
>
> window
> "Answer the receiver's window."
> #GLMWindowBrick asClassIfAbsent: [
> ^ self ownerThatIsA: SystemWindow ].
>
> ^ (self ownerThatIsA: #GLMWindowBrick asClass)
> ifNil: [ self ownerThatIsA: SystemWindow ]
>
>
>
> sendUsageData: aBoolean
> | settingsClass |
> settingsClass := #GTSpotterEventRecorderSettings asClassIfAbsent: [ ^ self ].
> ^ settingsClass sendUsageData: aBoolean
>
>
> sendUsageData
> | settingsClass |
> settingsClass := #GTSpotterEventRecorderSettings asClassIfAbsent: [ ^ false ].
> ^ settingsClass sendUsageData
>
>
April 10, 2015
Re: [Pharo-dev] why we removed debugTest from nautilus?
by Nicolai Hess
2015-04-10 2:37 GMT+02:00 Clément Bera <bera.clement(a)gmail.com>:
> I was using it frequently too and I have never experienced any issues...
>
Ok, can you describe a use case, what test case you can start and
close the debugger without image freeze?
Maybe we can find what is the difference between that
test case and those that freeze the image, and than find a fix.
>
> 2015-04-09 14:58 GMT-07:00 Nicolai Hess <nicolaihess(a)web.de>:
>
>
>> 2015-04-09 23:38 GMT+02:00 phil(a)highoctane.be <phil(a)highoctane.be>:
>>
>>> No Debug Tests?
>>>
>>> Geez, I am using that all the time.
>>>
>>
>> And you're never encountered this issue 14689
>> <https://pharo.fogbugz.com/default.asp?14689>?
>> Or did this work in older versions?
>>
>>
>>
>>
>>>
>>> Phil
>>>
>>>
>>> On Thu, Apr 9, 2015 at 10:21 PM, Marcus Denker <marcus.denker(a)inria.fr>
>>> wrote:
>>>
>>>>
>>>> > On 09 Apr 2015, at 22:32, Sean P. DeNigris <sean(a)clipperadams.com>
>>>> wrote:
>>>> >
>>>> > Nicolai Hess wrote
>>>> >>
>>>> http://forum.world.st/do-we-need-to-debug-testmethods-from-within-Nautilus-…
>>>> >
>>>> > Ah, I miss that too! From that thread, it seems it was removed
>>>> temporarily
>>>> > until we have real breakpoints. Is there an issue for its return?
>>>> >
>>>>
>>>> Not yet.
>>>>
>>>> Marcus
>>>>
>>>
>>>
>>
>
April 10, 2015
Re: [Pharo-dev] Existing <script> <example> pragmas and new GT needs
by Tudor Girba
Hi,
All methods from GT annotated with <gtExample> were renamed to #gtExample*.
So, the road for isExampleMethod is simpler.
Cheers,
Doru
On Thu, Apr 9, 2015 at 12:45 PM, Tudor Girba <tudor(a)tudorgirba.com> wrote:
> Hi,
>
>
>
> On Thu, Apr 9, 2015 at 12:31 PM, Nicolai Hess <nicolaihess(a)web.de> wrote:
>
>>
>>
>> 2015-04-09 11:53 GMT+02:00 Tudor Girba <tudor(a)tudorgirba.com>:
>>
>>> Hi,
>>>
>>> On Thu, Apr 9, 2015 at 11:44 AM, Nicolai Hess <nicolaihess(a)web.de>
>>> wrote:
>>>
>>>>
>>>>
>>>> 2015-04-09 11:36 GMT+02:00 Tudor Girba <tudor(a)tudorgirba.com>:
>>>>
>>>>> Hi,
>>>>>
>>>>> On Thu, Apr 9, 2015 at 11:31 AM, Nicolai Hess <nicolaihess(a)web.de>
>>>>> wrote:
>>>>>
>>>>>> 2015-04-09 8:48 GMT+02:00 Tudor Girba <tudor(a)tudorgirba.com>:
>>>>>>
>>>>>>> I would not do that. I think that removing the example pragma check
>>>>>>> is sufficient for now. Could we do it?
>>>>>>>
>>>>>>
>>>>>> Sufficient for what?
>>>>>>
>>>>>
>>>>> You said to add the extra check saying " *AND HAS NOT* a <example> (or
>>>>> <gtExample>) pragma "
>>>>> and I said that it is sufficient to just remove the pragma check for
>>>>> the Pharo 4 release :).
>>>>>
>>>>
>>>> No, I don't think this is enough. There are so many #exampleXXX method
>>>> from GT in the Pharo4 image
>>>> and most of them don't work with nautilus play-icon for #exampleXXX
>>>> methods
>>>>
>>>
>>> They don't do anything harmful either.
>>>
>>
>> No? We have now methods with the play icon that opens some
>> window/widget/... (The old examples)
>> And we have now many new example methods with this play icon that just do
>> nothing (visible).
>> I find this distracting.
>>
>>
>>
>>> But, you can also add the check as you suggest.
>>>
>>
>>
>> Well, I don't like this solution.
>> We would define a method to be an "example method" if it is *not* tagged
>> with <example> pragma.
>> This is confusing too.
>>
>
> Yes, that is why I said that we should not add that check :)
>
>
>> Possible solutions:
>> - remove the "run this example" play icon from nautilus, because with all
>> the new exampleXXX methods from GT
>> it is useless for ~half of all the methods.
>> - rename the example methods from GT to something else, so it does not
>> interfere with nautilus
>>
>
> Ok. We will rename the #example* methods from GT to gtExample* before the
> release.
>
>
>
>> - change the isExampleMethod check to *only* check for some
>> <OnWhatEverExamplePragmaWeAgree> and
>> tag all old (spec/widget/UI) example methods with this pragma.
>>
>
> I wish to have no pragma in isExampleMethod for Pharo 4. We can talk about
> it afterwards.
>
> But, we still need a pharo issue. Could you create one? :)
>
> Cheers,
> Doru
>
>
>>
>> For Pharo 4.0 I think we have to live with this mess and clean it up for
>> the next release.
>>
>>
>>
>>>
>>>
>>>>
>>>>
>>>>>
>>>>>
>>>>>> I think there is no problem if we remove the pragma check. Because
>>>>>> only very few (if any)
>>>>>>
>>>>>> example methods (those that really open an example) relies only on
>>>>>> the pragma, without having a #exampleXXX name too.
>>>>>>
>>>>>
>>>>> Exactly.
>>>>>
>>>>>
>>>>>> I just think this would not change much.
>>>>>> We need to clean up the mess with the #example* methods.
>>>>>>
>>>>>
>>>>> Thanks.
>>>>>
>>>>> Can you produce the issue and slice?
>>>>>
>>>>
>>>> For what, removing the example check or renaming all #example* methods
>>>> that don't open an example?
>>>>
>>>
>>> For removing the example check.
>>>
>>> Cheers,
>>> Doru
>>>
>>>
>>>>
>>>>
>>>>>
>>>>> @Torsten: are you fine with this?
>>>>>
>>>>> Doru
>>>>>
>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>>
>>>>>>> Cheers,
>>>>>>> Doru
>>>>>>>
>>>>>>> On Wed, Apr 8, 2015 at 5:16 PM, Nicolai Hess <nicolaihess(a)web.de>
>>>>>>> wrote:
>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> 2015-04-08 10:20 GMT+02:00 Tudor Girba <tudor(a)tudorgirba.com>:
>>>>>>>>
>>>>>>>>>
>>>>>>>>> And, to have a better chance of having a clean slate discussion
>>>>>>>>> later on in which to consider the value we associate to names, I would like
>>>>>>>>> to remove the <example> check from isExampleMethod and continue to preserve
>>>>>>>>> the treatment of #example* selectors in Nautilus.
>>>>>>>>>
>>>>>>>>>
>>>>>>>> Wouldn't we need to change the check to:
>>>>>>>>
>>>>>>>> isExampleMethod
>>>>>>>> if selector starts with 'example' *AND HAS NOT* a <example> (or
>>>>>>>> <gtExample>) pragma
>>>>>>>>
>>>>>>>> because there are tons of #example* methods, some of them open an
>>>>>>>> example and some of them with the pragma, create an instance for the
>>>>>>>> inspector?
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> www.tudorgirba.com
>>>>>>>
>>>>>>> "Every thing has its own flow"
>>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> www.tudorgirba.com
>>>>>
>>>>> "Every thing has its own flow"
>>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> www.tudorgirba.com
>>>
>>> "Every thing has its own flow"
>>>
>>
>>
>
>
> --
> www.tudorgirba.com
>
> "Every thing has its own flow"
>
--
www.tudorgirba.com
"Every thing has its own flow"
April 10, 2015
Re: [Pharo-dev] source code mgmt issues in Pharo4
by Johan Brichau
Hi Stef,
I sent my image to Thierry who found the cause of one issue. So thatâs very cool. Thx Thierry!
Unfortunately, there were other issues I had in other images and the problem with reporting an issue on the tracker right now is that I cannot reproduce and can only vaguely describe it.
So, until I hit it again⦠cannot say much. I hope to get back soon though :/
Johan
> On 09 Apr 2015, at 22:42, stepharo <stepharo(a)free.fr> wrote:
>
> Hi johan
>
> I usually attract bugs but not these ones.
> - I got debugger freezing
> - broken refactoring
> but not that ones. I would love to have a way to reproduce it.
>
> Stef
>
>
>
> Le 8/4/15 19:41, Johan Brichau a écrit :
>> Hi all,
>>
>> Over the last week, I started working with Pharo4, mostly to make Seaside work cleanly.
>>
>> On several occasions, I had severe issues with the package management:
>> - methods that were changed in a class were not recorded as âchangedâ in monticello and were absent from the published package
>> - versions of methods disappeared (i.e. no longer accessible in the version history of a method)
>> - looking at the âchangedâ in Monticello showed all code of the package as changed (though only a single method has changed).
>>
>> This makes working with Pharo4 extremely problematic. I cannot trust the source code packaging/publishing and merging anymore.
>>
>> I cannot discern a scenario that leads to these issues but I do have an image right now where I only changed a single method and the entire package shows up as âchangedâ.
>>
>> Anyone experience similar issues?
>>
>> Johan
>>
>
>
April 10, 2015
Re: [Pharo-dev] Problem with asClass usage
by phil@highoctane.be
Le 10 avr. 2015 08:10, "Peter Uhnák" <i.uhnak(a)gmail.com> a écrit :
>
> Why not add this to the critic browser?
>
> I'm quite guilty of doing this myself... because it is easier than
spending X amount of time of coming up with proper abstraction for
unimportant stuff instead of focusing on what I need....
Same. It is very useful to get code loading in a shorter way that Smalltalk
at: ...
#ConfigurationOfX asClass ...
is nicer than the other longer version.
For the GLM things, I guess it allows one to have code that works only if
an extra module is loaded.
We have asString and it is fine. Now asClass will not be. Duh?
aThing perform: #someAction is as complicated.
Yeah make a lint rule but do not disallow the usage.
Phil
>
> Peter
>
> On Fri, Apr 10, 2015 at 8:07 AM, stepharo <stepharo(a)free.fr> wrote:
>>
>>
>>
>> Le 10/4/15 06:09, Ben Coman a écrit :
>>>
>>> I believe #asClass itself was introduced for a use case to simplify
Workspace "user interactive" Gofer scripts to retrieve and load
Configurations. Since this is through away code its not covered by your
modularity concerns, and I'm not sure if it came before or after its
friends, but can we retain or substitute something to avoid needing
ugly "(Smalltalk at: #ConfigurationOfXXX) load" ?
>>
>>
>> For first time newbee they can also use the Configuration browser.
>> This is one click.
>>
>>>
>>> This is a "first impression" consideration for people dealing with
Configurations for the first time (even thought we now have Configuration
Browser). The use case is that newbies will copy-paste a script from a web
site to Playground and execute the whole script resulting in a error
"Unknown class ConfigurationOfXXX." They don't know to execute in two
separate steps, first "Gofer ... load" then "ConfigurationOfXXX load".
>>
>> Yes it would be much better.
>>
>>
>>>
>>> Alternatively, what if the Metacello package extended Gofer with a
method #configurationOf: so websites can show...
>>>
>>> config :=
>>> Gofer new
>>> url: 'http://smalltalkhub.com/mc/MyProject/main'
>>> package: 'MyXXXPackage';
>>> load;
>>> configurationOf: 'XXX' "return class ConfigurationOfXXX"
>>> config load.
>>>
>>> ...so the compiler is dealing with a variable "config" rather than
class 'ConfigurationOfXXX' that it doesn't know yet, or a further
altenative...
>>>
>>> Gofer new
>>> url: 'http://smalltalkhub.com/mc/MyProject/main'
>>> package: 'MyXXXPackage';
>>> load;
>>> configurationOf: 'XXX' do: [ :config | config load ];
>>> configurationOf: 'YYY' do: [ :config | config load ].
>>>
>>> cheers -ben
>>>
>>>
>>> On 10/04/2015 4:32 am, "stepharo" <stepharo(a)free.fr> wrote:
>>>>
>>>> Hi
>>>>
>>>> We want to raise a strong warning against the extension of the use of
asClass and friends.
>>>> asClass should not be used in Pharo distribution. I will propose to
deprecate it.
>>>>
>>>> We are working on dependency analysis, module system, remote debugging
and asClass introduces
>>>> lose class references and many related problems.
>>>>
>>>> I would like to remove this behavior because it is clear that it will
just grow up and lead to deadcode and ugly dependencies.
>>>>
>>>> First, most of the time you can avoid to query Smalltalk globals at:
and that BY CONSTRUCTION a software system should be built and it
should define its own customization.
>>>>
>>>>
>>>> Second, at least use self class environment at: #foo
>>>>
>>>> Why is it much much much better? because it does not rely on String
class resolution and as such
>>>> is much more modular. You do not want to have the resolution of a
symbol related to the place where String is defined but on where your code
is actually.
>>>>
>>>> Imagine that tomorrow your code is in its own module. Then you want to
know from your code point of you
>>>> if a binding exist not from the one of environment in which String is.
>>>>
>>>>
>>>>
>>>>
>>>> here are some examples:
>>>>
>>>> ==============================
>>>> quadrangleClass
>>>> ^ 'QuadrangleForTesting' asClass
>>>>
>>>> Strange it simply breaks. Of course it broke the smallLint rule.
>>>>
>>>> ==============================
>>>> Metacello should better define OSProcess as a dependent.Because it is
not clear what will happen
>>>> if if not there?
>>>>
>>>> extractRepositoryFrom: zipFile to: directory
>>>> "unzip <zipFile> into <directory>"
>>>>
>>>> | out err proc errorMessage |
>>>> out := FileStream forceNewFileNamed: '/tmp/zip.out'.
>>>> err := FileStream forceNewFileNamed: '/tmp/zip.err'.
>>>> errorMessage := ''.
>>>> [
>>>> proc := #OSProcess asClass thisOSProcess
>>>> forkJob: '/usr/bin/unzip'
>>>> arguments:
>>>> {'-u'.
>>>> zipFile.
>>>> '-d'.
>>>> directory}
>>>> environment: nil
>>>> descriptors: (Array with: nil with: out with: err).
>>>>
>>>> ==================
>>>>
>>>> I do not get why we need this funky logic.
>>>>
>>>> openInBrickWindowLabeled: aLabel
>>>>
>>>> #GLMSystemWindowBrick asClassIfAbsent: [
>>>> ^ self asMorph openInWindow ].
>>>>
>>>> ^ #GLMSystemWindowBrick asClass new
>>>> label: aLabel;
>>>> color: Color transparent;
>>>> addBrickBack: (
>>>> GLMBrick new
>>>> vSpaceFill
>>>>
>>>>
>>>> window
>>>> "Answer the receiver's window."
>>>> #GLMWindowBrick asClassIfAbsent: [
>>>> ^ self ownerThatIsA: SystemWindow ].
>>>>
>>>> ^ (self ownerThatIsA: #GLMWindowBrick asClass)
>>>> ifNil: [ self ownerThatIsA: SystemWindow ]
>>>>
>>>>
>>>>
>>>> sendUsageData: aBoolean
>>>> | settingsClass |
>>>> settingsClass := #GTSpotterEventRecorderSettings asClassIfAbsent:
[ ^ self ].
>>>> ^ settingsClass sendUsageData: aBoolean
>>>>
>>>>
>>>> sendUsageData
>>>> | settingsClass |
>>>> settingsClass := #GTSpotterEventRecorderSettings asClassIfAbsent:
[ ^ false ].
>>>> ^ settingsClass sendUsageData
>>>>
>>>>
>>
>
April 10, 2015
Re: [Pharo-dev] why we removed debugTest from nautilus?
by Esteban Lorenzano
> On 10 Apr 2015, at 02:37, Clément Bera <bera.clement(a)gmail.com> wrote:
>
> I was using it frequently too and I have never experienced any issuesâ¦
me too, and also never seen it.
but also never seen the issue⦠so I suppose is my fault not to talk in time :)
I will propose a replacement as soon as I can allocate some time to came up with something more or less well designed (bah⦠or designed âmy wayâ which is not always âwellâ :P).
Esteban
>
> 2015-04-09 14:58 GMT-07:00 Nicolai Hess <nicolaihess(a)web.de <mailto:nicolaihess@web.de>>:
>
> 2015-04-09 23:38 GMT+02:00 phil(a)highoctane.be <mailto:phil@highoctane.be> <phil(a)highoctane.be <mailto:phil@highoctane.be>>:
> No Debug Tests?
>
> Geez, I am using that all the time.
>
> And you're never encountered this issue 14689 <https://pharo.fogbugz.com/default.asp?14689>?
> Or did this work in older versions?
>
>
>
>
> Phil
>
>
> On Thu, Apr 9, 2015 at 10:21 PM, Marcus Denker <marcus.denker(a)inria.fr <mailto:marcus.denker@inria.fr>> wrote:
>
> > On 09 Apr 2015, at 22:32, Sean P. DeNigris <sean(a)clipperadams.com <mailto:sean@clipperadams.com>> wrote:
> >
> > Nicolai Hess wrote
> >> http://forum.world.st/do-we-need-to-debug-testmethods-from-within-Nautilus-… <http://forum.world.st/do-we-need-to-debug-testmethods-from-within-Nautilus-…>
> >
> > Ah, I miss that too! From that thread, it seems it was removed temporarily
> > until we have real breakpoints. Is there an issue for its return?
> >
>
> Not yet.
>
> Marcus
>
>
>
April 10, 2015
Re: [Pharo-dev] Problem with asClass usage
by Peter Uhnák
Why not add this to the critic browser?
I'm quite guilty of doing this myself... because it is easier than spending
X amount of time of coming up with proper abstraction for unimportant stuff
instead of focusing on what I need....
Peter
On Fri, Apr 10, 2015 at 8:07 AM, stepharo <stepharo(a)free.fr> wrote:
>
>
> Le 10/4/15 06:09, Ben Coman a écrit :
>
> I believe #asClass itself was introduced for a use case to simplify
> Workspace "user interactive" Gofer scripts to retrieve and load
> Configurations. Since this is through away code its not covered by your
> modularity concerns, and I'm not sure if it came before or after its
> friends, but can we retain or substitute something to avoid needing
> ugly "(Smalltalk at: #ConfigurationOfXXX) load" ?
>
>
> For first time newbee they can also use the Configuration browser.
> This is one click.
>
>
> This is a "first impression" consideration for people dealing with
> Configurations for the first time (even thought we now have Configuration
> Browser). The use case is that newbies will copy-paste a script from a web
> site to Playground and execute the whole script resulting in a error
> "Unknown class ConfigurationOfXXX." They don't know to execute in two
> separate steps, first "Gofer ... load" then "ConfigurationOfXXX load".
>
> Yes it would be much better.
>
>
>
> Alternatively, what if the Metacello package extended Gofer with a method
> #configurationOf: so websites can show...
>
> config :=
> Gofer new
> url: 'http://smalltalkhub.com/mc/MyProject/main'
> package: 'MyXXXPackage';
> load;
> configurationOf: 'XXX' "return class ConfigurationOfXXX"
> config load.
>
> ...so the compiler is dealing with a variable "config" rather than class
> 'ConfigurationOfXXX' that it doesn't know yet, or a further altenative...
>
> Gofer new
> url: 'http://smalltalkhub.com/mc/MyProject/main'
> package: 'MyXXXPackage';
> load;
> configurationOf: 'XXX' do: [ :config | config load ];
> configurationOf: 'YYY' do: [ :config | config load ].
>
> cheers -ben
>
>
> On 10/04/2015 4:32 am, "stepharo" <stepharo(a)free.fr> wrote:
>
>> Hi
>>
>> We want to raise a strong warning against the extension of the use of
>> asClass and friends.
>> asClass should not be used in Pharo distribution. I will propose to
>> deprecate it.
>>
>> We are working on dependency analysis, module system, remote debugging
>> and asClass introduces
>> lose class references and many related problems.
>>
>> I would like to remove this behavior because it is clear that it will
>> just grow up and lead to deadcode and ugly dependencies.
>>
>> First, most of the time you can avoid to query Smalltalk globals at: and
>> that BY CONSTRUCTION a software system should be built and it should
>> define its own customization.
>>
>>
>> Second, at least use self class environment at: #foo
>>
>> Why is it much much much better? because it does not rely on String class
>> resolution and as such
>> is much more modular. You do not want to have the resolution of a symbol
>> related to the place where String is defined but on where your code is
>> actually.
>>
>> Imagine that tomorrow your code is in its own module. Then you want to
>> know from your code point of you
>> if a binding exist not from the one of environment in which String is.
>>
>>
>>
>>
>> here are some examples:
>>
>> ==============================
>> quadrangleClass
>> ^ 'QuadrangleForTesting' asClass
>>
>> Strange it simply breaks. Of course it broke the smallLint rule.
>>
>> ==============================
>> Metacello should better define OSProcess as a dependent.Because it is not
>> clear what will happen
>> if if not there?
>>
>> extractRepositoryFrom: zipFile to: directory
>> "unzip <zipFile> into <directory>"
>>
>> | out err proc errorMessage |
>> out := FileStream forceNewFileNamed: '/tmp/zip.out'.
>> err := FileStream forceNewFileNamed: '/tmp/zip.err'.
>> errorMessage := ''.
>> [
>> proc := #OSProcess asClass thisOSProcess
>> forkJob: '/usr/bin/unzip'
>> arguments:
>> {'-u'.
>> zipFile.
>> '-d'.
>> directory}
>> environment: nil
>> descriptors: (Array with: nil with: out with: err).
>>
>> ==================
>>
>> I do not get why we need this funky logic.
>>
>> openInBrickWindowLabeled: aLabel
>>
>> #GLMSystemWindowBrick asClassIfAbsent: [
>> ^ self asMorph openInWindow ].
>>
>> ^ #GLMSystemWindowBrick asClass new
>> label: aLabel;
>> color: Color transparent;
>> addBrickBack: (
>> GLMBrick new
>> vSpaceFill
>>
>>
>> window
>> "Answer the receiver's window."
>> #GLMWindowBrick asClassIfAbsent: [
>> ^ self ownerThatIsA: SystemWindow ].
>>
>> ^ (self ownerThatIsA: #GLMWindowBrick asClass)
>> ifNil: [ self ownerThatIsA: SystemWindow ]
>>
>>
>>
>> sendUsageData: aBoolean
>> | settingsClass |
>> settingsClass := #GTSpotterEventRecorderSettings asClassIfAbsent: [ ^
>> self ].
>> ^ settingsClass sendUsageData: aBoolean
>>
>>
>> sendUsageData
>> | settingsClass |
>> settingsClass := #GTSpotterEventRecorderSettings asClassIfAbsent: [ ^
>> false ].
>> ^ settingsClass sendUsageData
>>
>>
>>
>
April 10, 2015
Re: [Pharo-dev] New Cog VMs available
by stepharo
There is no problem tobias
We love ci
Stef
Le 10/4/15 00:17, Tobias Pape a écrit :
> Sorry the noise, did not look on whereto I replied.
> :/
> Best
> -Tobias
>
>
> On 10.04.2015, at 00:16, Tobias Pape <Das.Linux(a)gmx.de> wrote:
>
>> Updated on the CI :)
>>
>> Best
>> -Tobias
>> On 09.04.2015, at 23:28, Eliot Miranda <eliot.miranda(a)gmail.com> wrote:
>>
>>> ... at http://www.mirandabanda.org/files/Cog/VM/VM.r3308/.
>>>
>>> CogVM binaries as per VMMaker.oscog-eem.1178/r3308
>>>
>>> Plugins:
>>> Integrate Nicolas' fixes that use positiveMachineIntegerFor: for pointers.
>>>
>>> Newspeak:
>>> Print a warning in the method shared under multiple selectors scenario.
>>>
>>> Implement outer sends as clean sends just like implicit receiver sends. Add
>>> ObjectRepresentation>>illegalClassTag and use it for initializing and unlinking
>>> implicit and outer sends.
>>>
>>> Newspeak & Sista:
>>> The multiple bytecode set block initial nil counters need
>>> to be specific to the bytecode set in effect.
>>>
>>> Spur:
>>> Implement Clement's much better solution for the stale supersend problem.
>>> Place code at the send site for super sends to follow stale forwarded
>>> receivers. This parallels the interpreter implementation.
>>>
>>> Beef up the post-become scan of send sites to
>>> unlink all send sites that link to an invalid class tag.
>>>
>>> Cogit:
>>> Optimize StackToRegisterMappingCogit>>genReturnReceiver
>>> to not load ReceiverResultReg if it already contains self.
>>>
>>> Revise method map generation to provide multiple send type annotations. Add
>>> an IsAnnotationExtension annotation type that implicitly has a zero displacement
>>> and uses its displacement bits to extend the preceeding IsSendCall annotation.
>>> This allows us to eliminate all the exotic entry-points and keep only the
>>> checked and unchecked entries.
>>>
>>> Change IA32's genPushRegisterArgsForNumArgs: to not smash TempReg now that it
>>> is used in directed super send trampolines.
>>>
>>> Use PushCq to pass small integer constants in the trampolines instead of
>>> smashing TempReg, which is now used to hold the directed supersend argument.
>>> Add support for PushCq. Could use PushCw but on x86 PushCq is a lot shorter.
>>>
>>> Mac builds: Use UTC as the timezone for the build timestamp. Using the local
>>> timezone doesn't work :(.
>
>
>
April 10, 2015
Re: [Pharo-dev] Problem with asClass usage
by stepharo
Le 10/4/15 06:09, Ben Coman a écrit :
> I believe #asClass itself was introduced for a use case to simplify
> Workspace "user interactive" Gofer scripts to retrieve and load
> Configurations. Since this is through away code its not covered by
> your modularity concerns, and I'm not sure if it came before or after
> its friends, but can we retain or substitute something to avoid
> needing ugly "(Smalltalk at: #ConfigurationOfXXX) load" ?
For first time newbee they can also use the Configuration browser.
This is one click.
> This is a "first impression" consideration for people dealing with
> Configurations for the first time (even thought we now have
> Configuration Browser). The use case is that newbies will copy-paste
> a script from a web site to Playground and execute the whole script
> resulting in a error "Unknown class ConfigurationOfXXX." They don't
> know to execute in two separate steps, first "Gofer ... load"
> then "ConfigurationOfXXX load".
Yes it would be much better.
> Alternatively, what if the Metacello package extended Gofer with a
> method #configurationOf: so websites can show...
> config :=
> Gofer new
> url: 'http://smalltalkhub.com/mc/MyProject/main'
> package: 'MyXXXPackage';
> load;
> configurationOf: 'XXX' "return class ConfigurationOfXXX"
> config load.
> ...so the compiler is dealing with a variable "config" rather than
> class 'ConfigurationOfXXX' that it doesn't know yet, or a further
> altenative...
> Gofer new
> url: 'http://smalltalkhub.com/mc/MyProject/main'
> package: 'MyXXXPackage';
> load;
> configurationOf: 'XXX' do: [ :config | config load ];
> configurationOf: 'YYY' do: [ :config | config load ].
> cheers -ben
> On 10/04/2015 4:32 am, "stepharo" <stepharo(a)free.fr
> <mailto:stepharo@free.fr>> wrote:
>
> Hi
>
> We want to raise a strong warning against the extension of the use
> of asClass and friends.
> asClass should not be used in Pharo distribution. I will propose
> to deprecate it.
>
> We are working on dependency analysis, module system, remote
> debugging and asClass introduces
> lose class references and many related problems.
>
> I would like to remove this behavior because it is clear that it
> will just grow up and lead to deadcode and ugly dependencies.
>
> First, most of the time you can avoid to query Smalltalk globals
> at: and that BY CONSTRUCTION a software system should be built
> and it should define its own customization.
>
>
> Second, at least use self class environment at: #foo
>
> Why is it much much much better? because it does not rely on
> String class resolution and as such
> is much more modular. You do not want to have the resolution of a
> symbol related to the place where String is defined but on where
> your code is actually.
>
> Imagine that tomorrow your code is in its own module. Then you
> want to know from your code point of you
> if a binding exist not from the one of environment in which String is.
>
>
>
>
> here are some examples:
>
> ==============================
> quadrangleClass
> ^ 'QuadrangleForTesting' asClass
>
> Strange it simply breaks. Of course it broke the smallLint rule.
>
> ==============================
> Metacello should better define OSProcess as a dependent.Because it
> is not clear what will happen
> if if not there?
>
> extractRepositoryFrom: zipFile to: directory
> "unzip <zipFile> into <directory>"
>
> | out err proc errorMessage |
> out := FileStream forceNewFileNamed: '/tmp/zip.out'.
> err := FileStream forceNewFileNamed: '/tmp/zip.err'.
> errorMessage := ''.
> [
> proc := #OSProcess asClass thisOSProcess
> forkJob: '/usr/bin/unzip'
> arguments:
> {'-u'.
> zipFile.
> '-d'.
> directory}
> environment: nil
> descriptors: (Array with: nil with: out with: err).
>
> ==================
>
> I do not get why we need this funky logic.
>
> openInBrickWindowLabeled: aLabel
>
> #GLMSystemWindowBrick asClassIfAbsent: [
> ^ self asMorph openInWindow ].
>
> ^ #GLMSystemWindowBrick asClass new
> label: aLabel;
> color: Color transparent;
> addBrickBack: (
> GLMBrick new
> vSpaceFill
>
>
> window
> "Answer the receiver's window."
> #GLMWindowBrick asClassIfAbsent: [
> ^ self ownerThatIsA: SystemWindow ].
>
> ^ (self ownerThatIsA: #GLMWindowBrick asClass)
> ifNil: [ self ownerThatIsA: SystemWindow ]
>
>
>
> sendUsageData: aBoolean
> | settingsClass |
> settingsClass := #GTSpotterEventRecorderSettings
> asClassIfAbsent: [ ^ self ].
> ^ settingsClass sendUsageData: aBoolean
>
>
> sendUsageData
> | settingsClass |
> settingsClass := #GTSpotterEventRecorderSettings
> asClassIfAbsent: [ ^ false ].
> ^ settingsClass sendUsageData
>
>
April 10, 2015