New and richer halt messages
I would love to have better halt messages. For example I would like to have - haltOnlyInTest - haltOnlyOutOfTest - haltOnlyMe that when I use this one disables all the other halt in the system. Marcus it would be nice to brainstorm on these to improve our halt vocabulary. Stef
Also why was haltIfShiftPressed removed? (in favor of haltIf: [ Sensor shiftPressed ], which is harder to write, remember, and without autocompletion). Peter On Fri, Jun 02, 2017 at 08:52:39AM +0200, Stephane Ducasse wrote:
I would love to have better halt messages.
For example I would like to have
- haltOnlyInTest - haltOnlyOutOfTest - haltOnlyMe that when I use this one disables all the other halt in the system.
Marcus it would be nice to brainstorm on these to improve our halt vocabulary. Stef
We will added back because it is nice indeed. On Fri, Jun 2, 2017 at 8:57 AM, Peter Uhnak <i.uhnak@gmail.com> wrote:
Also why was haltIfShiftPressed removed? (in favor of haltIf: [ Sensor shiftPressed ], which is harder to write, remember, and without autocompletion).
Peter
On Fri, Jun 02, 2017 at 08:52:39AM +0200, Stephane Ducasse wrote:
I would love to have better halt messages.
For example I would like to have
- haltOnlyInTest - haltOnlyOutOfTest - haltOnlyMe that when I use this one disables all the other halt in the system.
Marcus it would be nice to brainstorm on these to improve our halt vocabulary. Stef
Hi 2017-06-02 8:52 GMT+02:00 Stephane Ducasse <stepharo.self@gmail.com>:
- haltOnlyInTest - haltOnlyOutOfTest
With process specific variable CurrentExecutionEnvironment it should be very easy to implement. Halt will be delegated to DefaultExecutionEnvironment or TestExecutionEnvironment depending on current value.
2017-06-02 9:26 GMT+02:00 Denis Kudriashov <dionisiydk@gmail.com>:
2017-06-02 8:52 GMT+02:00 Stephane Ducasse <stepharo.self@gmail.com>:
- haltOnlyInTest - haltOnlyOutOfTest
With process specific variable CurrentExecutionEnvironment it should be very easy to implement. Halt will be delegated to DefaultExecutionEnvironment or TestExecutionEnvironment depending on current value.
And you are able to do it right now with following scripts: - haltOnlyInTest
self haltIf: [ CurrentExecutionEnvironment value isKindOf: TestExecutionEnvironment]
- haltOnlyOutOfTest
self haltIf: [ CurrentExecutionEnvironment value isKindOf: DefaultExecutionEnvironment]
Excellent! We should add them to the system. On Fri, Jun 2, 2017 at 10:00 AM, Denis Kudriashov <dionisiydk@gmail.com> wrote:
2017-06-02 9:26 GMT+02:00 Denis Kudriashov <dionisiydk@gmail.com>:
2017-06-02 8:52 GMT+02:00 Stephane Ducasse <stepharo.self@gmail.com>:
- haltOnlyInTest - haltOnlyOutOfTest
With process specific variable CurrentExecutionEnvironment it should be very easy to implement. Halt will be delegated to DefaultExecutionEnvironment or TestExecutionEnvironment depending on current value.
And you are able to do it right now with following scripts:
- haltOnlyInTest
self haltIf: [ CurrentExecutionEnvironment value isKindOf: TestExecutionEnvironment]
- haltOnlyOutOfTest
self haltIf: [ CurrentExecutionEnvironment value isKindOf: DefaultExecutionEnvironment]
2017-06-02 8:52 GMT+02:00 Stephane Ducasse <stepharo.self@gmail.com>:
For example I would like to have
- haltOnlyInTest - haltOnlyOutOfTest - haltOnlyMe that when I use this one disables all the other halt in the system.
Another question: do we really want new halt messages or it is better to extend breakpoints based on metalinks?
On 2 Jun 2017, at 09:28, Denis Kudriashov <dionisiydk@gmail.com> wrote:
2017-06-02 8:52 GMT+02:00 Stephane Ducasse <stepharo.self@gmail.com <mailto:stepharo.self@gmail.com>>: For example I would like to have
- haltOnlyInTest - haltOnlyOutOfTest - haltOnlyMe that when I use this one disables all the other halt in the system.
Another question: do we really want new halt messages or it is better to extend breakpoints based on metalinks?
I would go for metalinks. Esteban
I would go for simplicity. If we have a simple way to build then no need for metalink machinery On Fri, Jun 2, 2017 at 9:28 AM, Denis Kudriashov <dionisiydk@gmail.com> wrote:
2017-06-02 8:52 GMT+02:00 Stephane Ducasse <stepharo.self@gmail.com>:
For example I would like to have
- haltOnlyInTest - haltOnlyOutOfTest - haltOnlyMe that when I use this one disables all the other halt in the system.
Another question: do we really want new halt messages or it is better to extend breakpoints based on metalinks?
To mirror the existing API, what do you think of: - haltOnlyInTest -> #haltIfTest - haltOnlyOutOfTest -> #haltIfNotTest - haltOnlyMe -> #haltOnly ----- Cheers, Sean -- View this message in context: http://forum.world.st/New-and-richer-halt-messages-tp4948920p4949162.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
Sounds like a good idea, but please implement them as constructors/class side methods in Halt instead of adding even more methods to Object. "self haltIfTest -> Halt ifTest" Best regards, Henrik ________________________________ Fra: Pharo-dev <pharo-dev-bounces@lists.pharo.org> på vegne av Denis Kudriashov <dionisiydk@gmail.com> Sendt: 3. juni 2017 21:30:37 Til: Pharo Development List Emne: Re: [Pharo-dev] New and richer halt messages 2017-06-03 15:21 GMT+02:00 Sean P. DeNigris <sean@clipperadams.com<mailto:sean@clipperadams.com>>: To mirror the existing API, what do you think of: - haltOnlyInTest -> #haltIfTest - haltOnlyOutOfTest -> #haltIfNotTest - haltOnlyMe -> #haltOnly good names. We need right english overview :)
Henrik-Nergaard wrote
Sounds like a good idea, but please implement them as constructors/class side methods in Halt instead of adding even more methods to Object.
You're speaking my language! When Stephan Eggermont and I paired at ESUG creating the Halt API, we wanted to remove all the Object methods, but we were advised not to scare the users too much ha ha. Maybe the time has finally come?! ----- Cheers, Sean -- View this message in context: http://forum.world.st/New-and-richer-halt-messages-tp4948920p4949188.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.
On Sat, Jun 03, 2017 at 02:46:30PM -0700, Sean P. DeNigris wrote:
Henrik-Nergaard wrote
Sounds like a good idea, but please implement them as constructors/class side methods in Halt instead of adding even more methods to Object.
You're speaking my language! When Stephan Eggermont and I paired at ESUG creating the Halt API, we wanted to remove all the Object methods, but we were advised not to scare the users too much ha ha. Maybe the time has finally come?!
But then I wouldn't be able to write 1halt. :( Peter
2017-06-04 6:40 GMT-03:00 Peter Uhnak <i.uhnak@gmail.com>:
On Sat, Jun 03, 2017 at 02:46:30PM -0700, Sean P. DeNigris wrote:
Henrik-Nergaard wrote
Sounds like a good idea, but please implement them as constructors/class side methods in Halt instead of adding even more methods to Object.
You're speaking my language! When Stephan Eggermont and I paired at ESUG creating the Halt API, we wanted to remove all the Object methods, but we were advised not to scare the users too much ha ha. Maybe the time has finally come?!
But then I wouldn't be able to write 1halt. :(
I'd only leave #halt in Object, anything else goes to Halt class. I became a user of "1 halt" as well. Esteban A. Maringolo
Le 04/06/2017 à 11:40, Peter Uhnak a écrit :
But then I wouldn't be able to write 1halt. :(
Peter
You can still add some startup script :) I have one compiling a "h" method in object calling halt to be able to write "1h" :) -- Cyril Ferlicot https://ferlicot.fr http://www.synectique.eu 2 rue Jacques Prévert 01, 59650 Villeneuve d'ascq France
What we should consider is that well packaged methods can be in Object. The problem is when method in Object are used everywhere and that they have nothing to do there. About Halt only does not convey anything to me. Halt onlyMe means clearly what is it For the Halt ifTest Halt ifNotTest Why not. But I would prefer to be really clear. I would prefer Halt ifInsideTest Halt ifOutsideTest Because we are not about a couple of characters. Stef On Sun, Jun 4, 2017 at 3:09 PM, Cyril Ferlicot D. <cyril.ferlicot@gmail.com> wrote:
Le 04/06/2017 à 11:40, Peter Uhnak a écrit :
But then I wouldn't be able to write 1halt. :(
Peter
You can still add some startup script :)
I have one compiling a "h" method in object calling halt to be able to write "1h" :)
-- Cyril Ferlicot https://ferlicot.fr
http://www.synectique.eu 2 rue Jacques Prévert 01, 59650 Villeneuve d'ascq France
On Mon, Jun 5, 2017 at 5:06 AM, Stephane Ducasse <stepharo.self@gmail.com> wrote:
What we should consider is that well packaged methods can be in Object. The problem is when method in Object are used everywhere and that they have nothing to do there.
About Halt only does not convey anything to me. Halt onlyMe means clearly what is it
To me it seems strange/awkward that code in one method will change global debugging state, and it would feel better via direct UI action to add a metalink (IIUC how that would work.) Plus also a global GUI tool to manage breakpoints/metalinks would be good.
For the Halt ifTest Halt ifNotTest
Why not. But I would prefer to be really clear. I would prefer
Halt ifInsideTest Halt ifOutsideTest
These sound good. cheers -ben
Because we are not about a couple of characters.
Stef
On Sun, Jun 4, 2017 at 3:09 PM, Cyril Ferlicot D. < cyril.ferlicot@gmail.com> wrote:
Le 04/06/2017 à 11:40, Peter Uhnak a écrit :
But then I wouldn't be able to write 1halt. :(
Peter
You can still add some startup script :)
I have one compiling a "h" method in object calling halt to be able to write "1h" :)
-- Cyril Ferlicot https://ferlicot.fr
http://www.synectique.eu 2 rue Jacques Prévert 01, 59650 Villeneuve d'ascq France
About Halt only does not convey anything to me. Halt onlyMe means clearly what is it
To me it seems strange/awkward that code in one method will change global debugging state, and it would feel better via direct UI action to add a metalink (IIUC how that would work.) Plus also a global GUI tool to manage breakpoints/metalinks would be good. Yes but when you need you need it. Else what is the alternative: - remove all the halt during the execution. - execute yours - put back the halt if something wrong happens. or - create manually a global. - rewrite all your halt to depend on this global - turn on and off the global to get the desired effects... Tedious, cumbersome and boring. We can do better. On Mon, Jun 5, 2017 at 4:09 AM, Ben Coman <btc@openinworld.com> wrote:
On Mon, Jun 5, 2017 at 5:06 AM, Stephane Ducasse <stepharo.self@gmail.com> wrote:
What we should consider is that well packaged methods can be in Object. The problem is when method in Object are used everywhere and that they have nothing to do there.
About Halt only does not convey anything to me. Halt onlyMe means clearly what is it
To me it seems strange/awkward that code in one method will change global debugging state, and it would feel better via direct UI action to add a metalink (IIUC how that would work.) Plus also a global GUI tool to manage breakpoints/metalinks would be good.
For the Halt ifTest Halt ifNotTest
Why not. But I would prefer to be really clear. I would prefer
Halt ifInsideTest Halt ifOutsideTest
These sound good. cheers -ben
Because we are not about a couple of characters.
Stef
On Sun, Jun 4, 2017 at 3:09 PM, Cyril Ferlicot D. < cyril.ferlicot@gmail.com> wrote:
Le 04/06/2017 à 11:40, Peter Uhnak a écrit :
But then I wouldn't be able to write 1halt. :(
Peter
You can still add some startup script :)
I have one compiling a "h" method in object calling halt to be able to write "1h" :)
-- Cyril Ferlicot https://ferlicot.fr
http://www.synectique.eu 2 rue Jacques Prévert 01, 59650 Villeneuve d'ascq France
On Mon, Jun 5, 2017 at 5:01 PM, Stephane Ducasse <stepharo.self@gmail.com> wrote:
About
Halt only does not convey anything to me. Halt onlyMe means clearly what is it
To me it seems strange/awkward that code in one method will change global debugging state, and it would feel better via direct UI action to add a metalink (IIUC how that would work.) Plus also a global GUI tool to manage breakpoints/metalinks would be good.
Yes but when you need you need it. Else what is the alternative: - remove all the halt during the execution. - execute yours - put back the halt if something wrong happens.
or - create manually a global. - rewrite all your halt to depend on this global - turn on and off the global to get the desired effects...
or hypothetically something like... right-click code and menu select "break here, disable others" cheers -ben
Tedious, cumbersome and boring. We can do better.
On Mon, Jun 5, 2017 at 4:09 AM, Ben Coman <btc@openinworld.com> wrote:
On Mon, Jun 5, 2017 at 5:06 AM, Stephane Ducasse <stepharo.self@gmail.com
wrote:
What we should consider is that well packaged methods can be in Object. The problem is when method in Object are used everywhere and that they have nothing to do there.
About Halt only does not convey anything to me. Halt onlyMe means clearly what is it
To me it seems strange/awkward that code in one method will change global debugging state, and it would feel better via direct UI action to add a metalink (IIUC how that would work.) Plus also a global GUI tool to manage breakpoints/metalinks would be good.
For the Halt ifTest Halt ifNotTest
Why not. But I would prefer to be really clear. I would prefer
Halt ifInsideTest Halt ifOutsideTest
These sound good. cheers -ben
Because we are not about a couple of characters.
Stef
On Sun, Jun 4, 2017 at 3:09 PM, Cyril Ferlicot D. < cyril.ferlicot@gmail.com> wrote:
Le 04/06/2017 à 11:40, Peter Uhnak a écrit :
But then I wouldn't be able to write 1halt. :(
Peter
You can still add some startup script :)
I have one compiling a "h" method in object calling halt to be able to write "1h" :)
-- Cyril Ferlicot https://ferlicot.fr
http://www.synectique.eu 2 rue Jacques Prévert 01, 59650 Villeneuve d'ascq France
Could be but I like to have message too. Relying too much on tools is good but when suddently do not have tools because you are in a minimal kernel then having 3 extra messages should like a good win win situation. Stef On Mon, Jun 5, 2017 at 4:06 PM, Ben Coman <btc@openinworld.com> wrote:
On Mon, Jun 5, 2017 at 5:01 PM, Stephane Ducasse <stepharo.self@gmail.com> wrote:
About Halt only does not convey anything to me. Halt onlyMe means clearly what is it
To me it seems strange/awkward that code in one method will change global debugging state, and it would feel better via direct UI action to add a metalink (IIUC how that would work.) Plus also a global GUI tool to manage breakpoints/metalinks would be good.
Yes but when you need you need it. Else what is the alternative: - remove all the halt during the execution. - execute yours - put back the halt if something wrong happens.
or - create manually a global. - rewrite all your halt to depend on this global - turn on and off the global to get the desired effects...
or hypothetically something like... right-click code and menu select "break here, disable others"
cheers -ben
Tedious, cumbersome and boring. We can do better.
On Mon, Jun 5, 2017 at 4:09 AM, Ben Coman <btc@openinworld.com> wrote:
On Mon, Jun 5, 2017 at 5:06 AM, Stephane Ducasse <stepharo.self@gmail.com> wrote:
What we should consider is that well packaged methods can be in Object. The problem is when method in Object are used everywhere and that they have nothing to do there.
About Halt only does not convey anything to me. Halt onlyMe means clearly what is it
To me it seems strange/awkward that code in one method will change global debugging state, and it would feel better via direct UI action to add a metalink (IIUC how that would work.) Plus also a global GUI tool to manage breakpoints/metalinks would be good.
For the Halt ifTest Halt ifNotTest
Why not. But I would prefer to be really clear. I would prefer
Halt ifInsideTest Halt ifOutsideTest
These sound good. cheers -ben
Because we are not about a couple of characters.
Stef
On Sun, Jun 4, 2017 at 3:09 PM, Cyril Ferlicot D. <cyril.ferlicot@gmail.com> wrote:
Le 04/06/2017 à 11:40, Peter Uhnak a écrit :
But then I wouldn't be able to write 1halt. :(
Peter
You can still add some startup script :)
I have one compiling a "h" method in object calling halt to be able to write "1h" :)
-- Cyril Ferlicot https://ferlicot.fr
http://www.synectique.eu 2 rue Jacques Prévert 01, 59650 Villeneuve d'ascq France
A simple way of having a "onlyMe" type is to throw another type of error and wrap the code execution with an #on:do: catching and resuming Halt. Here is an example: ----------------------------------------------- | cls | cls := Halt subclass: #CustomHalt. cls class compile: 'onlyCustomHaltDuring: aBlock aBlock on: Halt - CustomHalt do: [ :ex | ex resume ] '. cls class compile: 'example self onlyCustomHaltDuring: [ 0 crLog. Halt now. 1 crLog. Halt once. 2 crLog. CustomHalt now. 3 crLog. ] '. cls example ----------------------------------------------- Best regards, Henrik ________________________________ Fra: Pharo-dev <pharo-dev-bounces@lists.pharo.org> på vegne av Stephane Ducasse <stepharo.self@gmail.com> Sendt: 5. juni 2017 20:57:43 Til: Pharo Development List Emne: Re: [Pharo-dev] New and richer halt messages Could be but I like to have message too. Relying too much on tools is good but when suddently do not have tools because you are in a minimal kernel then having 3 extra messages should like a good win win situation. Stef On Mon, Jun 5, 2017 at 4:06 PM, Ben Coman <btc@openinworld.com> wrote:
On Mon, Jun 5, 2017 at 5:01 PM, Stephane Ducasse <stepharo.self@gmail.com> wrote:
About Halt only does not convey anything to me. Halt onlyMe means clearly what is it
To me it seems strange/awkward that code in one method will change global debugging state, and it would feel better via direct UI action to add a metalink (IIUC how that would work.) Plus also a global GUI tool to manage breakpoints/metalinks would be good.
Yes but when you need you need it. Else what is the alternative: - remove all the halt during the execution. - execute yours - put back the halt if something wrong happens.
or - create manually a global. - rewrite all your halt to depend on this global - turn on and off the global to get the desired effects...
or hypothetically something like... right-click code and menu select "break here, disable others"
cheers -ben
Tedious, cumbersome and boring. We can do better.
On Mon, Jun 5, 2017 at 4:09 AM, Ben Coman <btc@openinworld.com> wrote:
On Mon, Jun 5, 2017 at 5:06 AM, Stephane Ducasse <stepharo.self@gmail.com> wrote:
What we should consider is that well packaged methods can be in Object. The problem is when method in Object are used everywhere and that they have nothing to do there.
About Halt only does not convey anything to me. Halt onlyMe means clearly what is it
To me it seems strange/awkward that code in one method will change global debugging state, and it would feel better via direct UI action to add a metalink (IIUC how that would work.) Plus also a global GUI tool to manage breakpoints/metalinks would be good.
For the Halt ifTest Halt ifNotTest
Why not. But I would prefer to be really clear. I would prefer
Halt ifInsideTest Halt ifOutsideTest
These sound good. cheers -ben
Because we are not about a couple of characters.
Stef
On Sun, Jun 4, 2017 at 3:09 PM, Cyril Ferlicot D. <cyril.ferlicot@gmail.com> wrote:
Le 04/06/2017 à 11:40, Peter Uhnak a écrit :
But then I wouldn't be able to write 1halt. :(
Peter
You can still add some startup script :)
I have one compiling a "h" method in object calling halt to be able to write "1h" :)
-- Cyril Ferlicot https://ferlicot.fr
http://www.synectique.eu 2 rue Jacques Prévert 01, 59650 Villeneuve d'ascq France
Nice idea. On Wed, Jun 7, 2017 at 5:34 AM, Henrik Nergaard <draagren@outlook.com> wrote:
A simple way of having a "onlyMe" type is to throw another type of error and wrap the code execution with an #on:do: catching and resuming Halt.
Here is an example:
-----------------------------------------------
| cls |
cls := Halt subclass: #CustomHalt.
cls class compile: 'onlyCustomHaltDuring: aBlock
This sending #class to a Class confused me for a bit. I wonder if these might be useful, just aliased to #class... cls classSide compile: 'onlyCustomHaltDuring: aBlock cls meta compile: 'onlyCustomHaltDuring: aBlock cheers -ben aBlock on: Halt - CustomHalt do: [ :ex | ex resume ]
'.
cls class compile: 'example self onlyCustomHaltDuring: [ 0 crLog. Halt now. 1 crLog. Halt once. 2 crLog. CustomHalt now. 3 crLog. ] '.
cls example -----------------------------------------------
Best regards,
Henrik ------------------------------ *Fra:* Pharo-dev <pharo-dev-bounces@lists.pharo.org> på vegne av Stephane Ducasse <stepharo.self@gmail.com> *Sendt:* 5. juni 2017 20:57:43 *Til:* Pharo Development List *Emne:* Re: [Pharo-dev] New and richer halt messages
Could be but I like to have message too. Relying too much on tools is good but when suddently do not have tools because you are in a minimal kernel then having 3 extra messages should like a good win win situation.
Stef
On Mon, Jun 5, 2017 at 4:06 PM, Ben Coman <btc@openinworld.com> wrote:
On Mon, Jun 5, 2017 at 5:01 PM, Stephane Ducasse <
stepharo.self@gmail.com>
wrote:
About Halt only does not convey anything to me. Halt onlyMe means clearly what is it
To me it seems strange/awkward that code in one method will change global debugging state, and it would feel better via direct UI action to add a metalink (IIUC how that would work.) Plus also a global GUI tool to manage breakpoints/metalinks would be good.
Yes but when you need you need it. Else what is the alternative: - remove all the halt during the execution. - execute yours - put back the halt if something wrong happens.
or - create manually a global. - rewrite all your halt to depend on this global - turn on and off the global to get the desired effects...
or hypothetically something like... right-click code and menu select "break here, disable others"
cheers -ben
Tedious, cumbersome and boring. We can do better.
On Mon, Jun 5, 2017 at 4:09 AM, Ben Coman <btc@openinworld.com> wrote:
On Mon, Jun 5, 2017 at 5:06 AM, Stephane Ducasse <stepharo.self@gmail.com> wrote:
What we should consider is that well packaged methods can be in
Object.
The problem is when method in Object are used everywhere and that they have nothing to do there.
About Halt only does not convey anything to me. Halt onlyMe means clearly what is it
To me it seems strange/awkward that code in one method will change global debugging state, and it would feel better via direct UI action to add a metalink (IIUC how that would work.) Plus also a global GUI tool to manage breakpoints/metalinks would be good.
For the Halt ifTest Halt ifNotTest
Why not. But I would prefer to be really clear. I would prefer
Halt ifInsideTest Halt ifOutsideTest
These sound good. cheers -ben
Because we are not about a couple of characters.
Stef
On Sun, Jun 4, 2017 at 3:09 PM, Cyril Ferlicot D. <cyril.ferlicot@gmail.com> wrote:
Le 04/06/2017 à 11:40, Peter Uhnak a écrit :
But then I wouldn't be able to write 1halt. :(
Peter
You can still add some startup script :)
I have one compiling a "h" method in object calling halt to be able
to
write "1h" :)
-- Cyril Ferlicot https://ferlicot.fr
http://www.synectique.eu 2 rue Jacques Prévert 01, 59650 Villeneuve d'ascq France
participants (9)
-
Ben Coman -
Cyril Ferlicot D. -
Denis Kudriashov -
Esteban A. Maringolo -
Esteban Lorenzano -
Henrik Nergaard -
Peter Uhnak -
Sean P. DeNigris -
Stephane Ducasse