[Pharo-users] Re: We haven't had a design debate in a while - thoughts on CD.buy article...

2021-04-16 Thread Richard Sargent
I remember - way back in the dark ages - walking into a music store,
picking up a CD, and asking it to buy itself. Every single time, the
response was the same: nothing.

On Fri, Apr 16, 2021 at 10:07 AM Tim Mackinnon  wrote:

> Its comforting to see that other have the same reaction as me - I agree
> with the sentiment that you send messages to objects - and the naming of
> those messages and their context is important.
>
> and CD.buy - is at least a message to an object but as others have
> commented, it  highlights flaws in the context or modelling as it just
> doesn't read right. I'd model it different too.
>
> Phew, I'm not losing it
>
> Tim
>
> On Fri, 16 Apr 2021, at 2:44 PM, Russ Whaley wrote:
>
> Wow, I must be missing a whole lot of context in that discussion...
> (instant reaction as well, lol)
>
> - a product (CD, book, etc.) does not 'buy' - it can be bought, sure, but
> it has no buying action.  Even in another context a CD does not 'play'...
> aMusicPlayer.play(aCD).
> - However, a customer can 'buy' a product...
>
>- customer.buy(aCD) -or-
>- customer.addToCart(aCD)
>- customer.checkOut(aCart)
>- Invoice.new(aCart), etc.
>
> - ... but the CD doesn't DO anything.
>
> - I get the idea that different products might have different behaviour
> when they are 'bought' - but these are, in this example, fulfillment - not
> the 'buy' action...
>
>- aCDstream might be set for download
>- aCDphysical might be set to physically pull off a shelf and ship
>- aCDcare might send an email on warranty, whatever... but let's name
>it better than 'buy' :)
>
> Tim, thanks for the link - I'm always trying to expand my thinking about
> object modeling - discovering cool ways/things others are thinking
> about...  Now I have to go dust off all my old POS (point of sale, not
> piece of s#&t) code and see how poorly I may have modeled those
> environments!!
>
> Thanks for the morning diversion!  Cheers.
>
> On Fri, Apr 16, 2021 at 8:53 AM Esteban Maringolo 
> wrote:
>
> I saw a tweet about that, and I think that the example is misleading,
> maybe intentionally so.
>
> I don't think anybody would model it that way, in any case you'd have
> aProduct.buy() or aProduct.addToCart(aCart).
>
> If you think it with the typical dog.bark() it certainly makes more sense
> than bark(dog).
>
> Regards!
>
> Esteban A. Maringolo
>
>
> On Fri, Apr 16, 2021 at 5:20 AM Tim Mackinnon  wrote:
>
> Hi guys - someone pointed out this article from a UK colleague which seems
> to be causing a flurry of discussion - but I always like the insights of
> this group. I had an instant reaction when I read it - but curious what
> people here think in 2021.
>
>
> https://www.linkedin.com/posts/jasongorman_the-year-is-2021-and-people-still-think-activity-6787650079764303872-SJzz
>
> Tim
>
>
>
> --
> Russ Whaley
> whaley.r...@gmail.com
>
>
>


[Pharo-users] Re: We haven't had a design debate in a while - thoughts on CD.buy article...

2021-04-16 Thread Tim Mackinnon
Its comforting to see that other have the same reaction as me - I agree with 
the sentiment that you send messages to objects - and the naming of those 
messages and their context is important.

and CD.buy - is at least a message to an object but as others have commented, 
it  highlights flaws in the context or modelling as it just doesn't read right. 
I'd model it different too.

Phew, I'm not losing it

Tim

On Fri, 16 Apr 2021, at 2:44 PM, Russ Whaley wrote:
> Wow, I must be missing a whole lot of context in that discussion...  (instant 
> reaction as well, lol)
> 
> - a product (CD, book, etc.) does not 'buy' - it can be bought, sure, but it 
> has no buying action.  Even in another context a CD does not 'play'... 
> aMusicPlayer.play(aCD).
> - However, a customer can 'buy' a product... 
>  * customer.buy(aCD) -or-
>  * customer.addToCart(aCD)
>  * customer.checkOut(aCart)
>  * Invoice.new(aCart), etc. 
> - ... but the CD doesn't DO anything. 
> 
> - I get the idea that different products might have different behaviour when 
> they are 'bought' - but these are, in this example, fulfillment - not the 
> 'buy' action... 
>  * aCDstream might be set for download
>  * aCDphysical might be set to physically pull off a shelf and ship
>  * aCDcare might send an email on warranty, whatever... but let's name it 
> better than 'buy' :)
> Tim, thanks for the link - I'm always trying to expand my thinking about 
> object modeling - discovering cool ways/things others are thinking about...  
> Now I have to go dust off all my old POS (point of sale, not piece of s#&t) 
> code and see how poorly I may have modeled those environments!!
> 
> Thanks for the morning diversion!  Cheers.
> 
> On Fri, Apr 16, 2021 at 8:53 AM Esteban Maringolo  
> wrote:
>> I saw a tweet about that, and I think that the example is misleading, maybe 
>> intentionally so.
>> 
>> I don't think anybody would model it that way, in any case you'd have 
>> aProduct.buy() or aProduct.addToCart(aCart). 
>> 
>> If you think it with the typical dog.bark() it certainly makes more sense 
>> than bark(dog).
>> 
>> Regards!
>> 
>> Esteban A. Maringolo
>> 
>> 
>> On Fri, Apr 16, 2021 at 5:20 AM Tim Mackinnon  wrote:
>>> Hi guys - someone pointed out this article from a UK colleague which seems 
>>> to be causing a flurry of discussion - but I always like the insights of 
>>> this group. I had an instant reaction when I read it - but curious what 
>>> people here think in 2021.
>>> 
>>> https://www.linkedin.com/posts/jasongorman_the-year-is-2021-and-people-still-think-activity-6787650079764303872-SJzz
>>> 
>>> Tim
> 
> 
> -- 
> Russ Whaley
> whaley.r...@gmail.com


[Pharo-users] Re: Crash after http request, see the dump file

2021-04-16 Thread David Pennington
Nope. Just stderr. It is continuing to happy at random times so it is obviously 
connected to page requests. I have some logging in. Place so I have increased 
that to try and help get to the point where it happens.

David

> On 16 Apr 2021, at 15:45, Davide Varvello via Pharo-users 
>  wrote:
> 
> Hi David,
> Usually when the image crashes you'll find a crash.dmp file.
> It's weird there isn't anything
> Davide
> 
> 
> Long Haired David wrote
>> Sorry to but in here but I have just moved my Pharo/Seaside server
>> software from my MacBookAir, where it has run without issue for the last
>> couple of weeks, onto firstly a Lenovo desktop running Windows 2012 server
>> and then, in frustration , onto a Dell laptop but it hasn’t managed to run
>> for 24 hours without crashing (by crashing, I mean Pharo just
>> disappears!). I don’t us any OsProcess, just ordinary Seaside and
>> Smalltalk code. It has happened three days in a row at different times
>> with different pages being accessed.
>> 
>> Both Windows machines have ample disk space (SSD) and 16GB memory.
>> 
>> How do I get a dump as I can’t see any files that would be regarded as so?
>> 
>> David
>> 
>>> On 15 Apr 2021, at 14:55, Guillermo Polito <
> 
>> guillermopolito@
> 
>> > wrote:
>>> 
>>> Hi Davide,
>>> 
>>> Taking a look at the dump, I’d say it looks like a memory corruption.
>>> It crashes when running the GC, but very probably because the heap was
>>> already corrupt.
>>> 
>>> 
>>> 5   Pharo   0x00010582ea3b mapStackPages
>>> + 345
>>> 6   Pharo   0x00010582e0ff
>>> mapInterpreterOops + 16
>>> 7   Pharo   0x00010580af54 doScavenge +
>>> 648
>>> 8   Pharo   0x00010581305e
>>> scavengingGCTenuringIf + 333
>>> 9   Pharo   0x0001057f663a
>>> checkForEventsMayContextSwitch + 111
>>> 10  Pharo   0x0001057fa815
>>> ceStackOverflow + 110
>>> 11  ??? 0x00010b25c62b 0x0 +
>>> 4481992235
>>> 12  Pharo   0x0001057e2b0a interpret +
>>> 632
>>> 
>>> Does this happen often in your setup?
>>> 
>>> G
>>> 
>>> 
 El 14 abr 2021, a las 10:21, Davide Varvello via Pharo-users <
> 
>> pharo-users@.pharo
> 
>>  
>> pharo-users@.pharo
> 
>> >> escribió:
 
 Hi Sven,
 It has not happened today. I also use a lot of OsProcess, but I don't
 know
 if it is related to it.
 Cheers
 Davide
 
 
 
 Sven Van Caekenberghe-2 wrote
> I can't see anything networking, HTTP or Zinc related in the dump.
> It looks like something went wrong during garbage collection.
> I suppose this is not a repeatable case, is it ?
> 
>> On 14 Apr 2021, at 09:22, Davide Varvello via Pharo-users <
 
> pharo-users@.pharo
 
> > wrote:
>> 
>> Hi guys,
>> I'm working on Pharo 8 on BigSur 
>> (Pharo 8.0.0 Build information:
>> Pharo-8.0.0+build.1128.sha.9f6475d88dda7d83acdeeda794df35d304cf620d
>> (64
>> Bit))
>> 
>> Yesterday after an http call to my zinc server the image crashed.
>> Can you please take a look to the dump file and tell me what happened?
>> 
>> It would be worth so much to me, thank you
>> 
>> The file is here: https://pastebin.com/SrE6gcCv
>> ;
>> 
>> 
>> Davide
>> 
>> 
>> 
>> --
>> Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html
>> ;
 
 
 
 
 
 --
 Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html
 ;
> 
> 
> 
> 
> 
> --
> Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html


[Pharo-users] Re: Crash after http request, see the dump file

2021-04-16 Thread Davide Varvello via Pharo-users
Hi David,
Usually when the image crashes you'll find a crash.dmp file.
It's weird there isn't anything
Davide


Long Haired David wrote
> Sorry to but in here but I have just moved my Pharo/Seaside server
> software from my MacBookAir, where it has run without issue for the last
> couple of weeks, onto firstly a Lenovo desktop running Windows 2012 server
> and then, in frustration , onto a Dell laptop but it hasn’t managed to run
> for 24 hours without crashing (by crashing, I mean Pharo just
> disappears!). I don’t us any OsProcess, just ordinary Seaside and
> Smalltalk code. It has happened three days in a row at different times
> with different pages being accessed.
> 
> Both Windows machines have ample disk space (SSD) and 16GB memory.
> 
> How do I get a dump as I can’t see any files that would be regarded as so?
> 
> David
> 
>> On 15 Apr 2021, at 14:55, Guillermo Polito <

> guillermopolito@

> > wrote:
>> 
>> Hi Davide,
>> 
>> Taking a look at the dump, I’d say it looks like a memory corruption.
>> It crashes when running the GC, but very probably because the heap was
>> already corrupt.
>> 
>> 
>> 5   Pharo   0x00010582ea3b mapStackPages
>> + 345
>> 6   Pharo   0x00010582e0ff
>> mapInterpreterOops + 16
>> 7   Pharo   0x00010580af54 doScavenge +
>> 648
>> 8   Pharo   0x00010581305e
>> scavengingGCTenuringIf + 333
>> 9   Pharo   0x0001057f663a
>> checkForEventsMayContextSwitch + 111
>> 10  Pharo   0x0001057fa815
>> ceStackOverflow + 110
>> 11  ??? 0x00010b25c62b 0x0 +
>> 4481992235
>> 12  Pharo   0x0001057e2b0a interpret +
>> 632
>> 
>> Does this happen often in your setup?
>> 
>> G
>> 
>> 
>>> El 14 abr 2021, a las 10:21, Davide Varvello via Pharo-users <

> pharo-users@.pharo

>   pharo-users@.pharo

> >> escribió:
>>> 
>>> Hi Sven,
>>> It has not happened today. I also use a lot of OsProcess, but I don't
>>> know
>>> if it is related to it.
>>> Cheers
>>> Davide
>>> 
>>> 
>>> 
>>> Sven Van Caekenberghe-2 wrote
 I can't see anything networking, HTTP or Zinc related in the dump.
 It looks like something went wrong during garbage collection.
 I suppose this is not a repeatable case, is it ?
 
> On 14 Apr 2021, at 09:22, Davide Varvello via Pharo-users <
>>> 
 pharo-users@.pharo
>>> 
 > wrote:
> 
> Hi guys,
> I'm working on Pharo 8 on BigSur 
> (Pharo 8.0.0 Build information:
> Pharo-8.0.0+build.1128.sha.9f6475d88dda7d83acdeeda794df35d304cf620d
> (64
> Bit))
> 
> Yesterday after an http call to my zinc server the image crashed.
> Can you please take a look to the dump file and tell me what happened?
> 
> It would be worth so much to me, thank you
> 
> The file is here: https://pastebin.com/SrE6gcCv
> ;
> 
> 
> Davide
> 
> 
> 
> --
> Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html
> ;
>>> 
>>> 
>>> 
>>> 
>>> 
>>> --
>>> Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html
>>> ;





--
Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html


[Pharo-users] Re: We haven't had a design debate in a while - thoughts on CD.buy article...

2021-04-16 Thread Russ Whaley
Wow, I must be missing a whole lot of context in that discussion...
(instant reaction as well, lol)

- a product (CD, book, etc.) does not 'buy' - it can be bought, sure, but
it has no buying action.  Even in another context a CD does not 'play'...
aMusicPlayer.play(aCD).
- However, a customer can 'buy' a product...

   - customer.buy(aCD) -or-
   - customer.addToCart(aCD)
   - customer.checkOut(aCart)
   - Invoice.new(aCart), etc.

- ... but the CD doesn't DO anything.

- I get the idea that different products might have different behaviour
when they are 'bought' - but these are, in this example, fulfillment - not
the 'buy' action...

   - aCDstream might be set for download
   - aCDphysical might be set to physically pull off a shelf and ship
   - aCDcare might send an email on warranty, whatever... but let's name it
   better than 'buy' :)

Tim, thanks for the link - I'm always trying to expand my thinking about
object modeling - discovering cool ways/things others are thinking
about...  Now I have to go dust off all my old POS (point of sale, not
piece of s#&t) code and see how poorly I may have modeled those
environments!!

Thanks for the morning diversion!  Cheers.

On Fri, Apr 16, 2021 at 8:53 AM Esteban Maringolo 
wrote:

> I saw a tweet about that, and I think that the example is misleading,
> maybe intentionally so.
>
> I don't think anybody would model it that way, in any case you'd have
> aProduct.buy() or aProduct.addToCart(aCart).
>
> If you think it with the typical dog.bark() it certainly makes more sense
> than bark(dog).
>
> Regards!
>
> Esteban A. Maringolo
>
>
> On Fri, Apr 16, 2021 at 5:20 AM Tim Mackinnon  wrote:
>
>> Hi guys - someone pointed out this article from a UK colleague which
>> seems to be causing a flurry of discussion - but I always like the insights
>> of this group. I had an instant reaction when I read it - but curious what
>> people here think in 2021.
>>
>>
>> https://www.linkedin.com/posts/jasongorman_the-year-is-2021-and-people-still-think-activity-6787650079764303872-SJzz
>>
>> Tim
>>
>

-- 
Russ Whaley
whaley.r...@gmail.com


[Pharo-users] Re: We haven't had a design debate in a while - thoughts on CD.buy article...

2021-04-16 Thread Esteban Maringolo
I saw a tweet about that, and I think that the example is misleading, maybe
intentionally so.

I don't think anybody would model it that way, in any case you'd have
aProduct.buy() or aProduct.addToCart(aCart).

If you think it with the typical dog.bark() it certainly makes more sense
than bark(dog).

Regards!

Esteban A. Maringolo


On Fri, Apr 16, 2021 at 5:20 AM Tim Mackinnon  wrote:

> Hi guys - someone pointed out this article from a UK colleague which seems
> to be causing a flurry of discussion - but I always like the insights of
> this group. I had an instant reaction when I read it - but curious what
> people here think in 2021.
>
>
> https://www.linkedin.com/posts/jasongorman_the-year-is-2021-and-people-still-think-activity-6787650079764303872-SJzz
>
> Tim
>


[Pharo-users] We haven't had a design debate in a while - thoughts on CD.buy article...

2021-04-16 Thread Tim Mackinnon
Hi guys - someone pointed out this article from a UK colleague which seems to 
be causing a flurry of discussion - but I always like the insights of this 
group. I had an instant reaction when I read it - but curious what people here 
think in 2021.

https://www.linkedin.com/posts/jasongorman_the-year-is-2021-and-people-still-think-activity-6787650079764303872-SJzz

Tim