How to use development tools with a "consumer application VM image"

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

How to use development tools with a "consumer application VM image"

Michael Vorburger-2
Hello Squeakers!

How do you "peek" into it a Squeak image like the one Scratch
distributes, so to see and learn from the Scratch classes and methods
etc. and "hack" (in the best sense of the word) it?

My understanding is that such an image is made "consumer friendly"
(what's the term you use for doing things like what's described on
http://squeak.preeminent.org/tut2007/html/205.html ?), so when the VM
starts, it immediately shows that "application" only, right-clicks are
overloaded, and one can not access e.g. a Browser, Workspace etc.
development tools anymore, if they even are still part of this kind of
images.

I am curious how Smalltalk/Squeak handles this issue that probably
isn't new to many of you on the list. Can one either "load" (parts of)
an image into a running "full/normal" image which has development
tools, or can I add back those tools to such an image externally
somehow? Surely that is not impossible, no image presumably can
effectively completely "lock out" development, or can it?

Thanks a lot,
Michael
_______________________________________________
Beginners mailing list
[hidden email]
http://lists.squeakfoundation.org/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Frozen Squeak environment

Peter Mucsi
Hi,

I'm a newbee playing around in Squeak for a while.

Sometimes I write code that is faulty, for example, execution gets into
an infinite loop. If the loop doesn't stop after a while, the whole
environment gets frozen and I have to kill Squeak in Windows XP. I have
tried #forkAt (I put my stuff into a BlockClosure instance), it has
solved the problem, but is there a way in Squeak to do this
automatically? Can I execute something in Workspace that is put
automatically into a low priority thread?

Thanks in advance for your  kind answer.

Peter Mucsi
_______________________________________________
Beginners mailing list
[hidden email]
http://lists.squeakfoundation.org/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: Frozen Squeak environment

Benjamin Schroeder-2

On Aug 5, 2007, at 10:03 AM, Peter Mucsi wrote:

> Hi,
>
> I'm a newbee playing around in Squeak for a while.
>
> Sometimes I write code that is faulty, for example, execution gets  
> into an infinite loop. If the loop doesn't stop after a while, the  
> whole environment gets frozen and I have to kill Squeak in Windows  
> XP. I have tried #forkAt (I put my stuff into a BlockClosure  
> instance), it has solved the problem, but is there a way in Squeak  
> to do this automatically? Can I execute something in Workspace that  
> is put automatically into a low priority thread?

Hi Peter,

One thing you can do if you do get stuck in an infinite loop is to  
press alt-. (alt-period).* This will interrupt the currently  
executing thread. Squeak will bring up a walkback window which you  
can use as a debugger on the stopped thread, or just close to move on.

(I know this doesn't answer the question directly! You could make a  
Workspace that forked things off without too much work, although  
there isn't such a thing built in AFAIK. Check out #evaluateSelection  
in ParagraphEditor to see where workspaces, etc., evaluate code. Of  
course there are twisty parts: e.g., you'd then have to manage  
stopping processes that ran too long, since they would still run in  
the background and use up resources.)

Hope this helps,
Benjamin Schroeder

* At least I think this is right. For me, on Mac, it's command-
period, so I think it's alt-period on XP. It could be ctrl-period if  
not.

_______________________________________________
Beginners mailing list
[hidden email]
http://lists.squeakfoundation.org/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: Frozen Squeak environment

Peter Mucsi
Hi Benjamin,

Alt-period worked well on Windows too. Basically all I wanted is not to
lose my work if I do something silly.

Thanks a lot!


Regards,
Peter

Benjamin Schroeder wrote:

>
> On Aug 5, 2007, at 10:03 AM, Peter Mucsi wrote:
>
>> Hi,
>>
>> I'm a newbee playing around in Squeak for a while.
>>
>> Sometimes I write code that is faulty, for example, execution gets
>> into an infinite loop. If the loop doesn't stop after a while, the
>> whole environment gets frozen and I have to kill Squeak in Windows
>> XP. I have tried #forkAt (I put my stuff into a BlockClosure
>> instance), it has solved the problem, but is there a way in Squeak to
>> do this automatically? Can I execute something in Workspace that is
>> put automatically into a low priority thread?
>
> Hi Peter,
>
> One thing you can do if you do get stuck in an infinite loop is to
> press alt-. (alt-period).* This will interrupt the currently executing
> thread. Squeak will bring up a walkback window which you can use as a
> debugger on the stopped thread, or just close to move on.
>
> (I know this doesn't answer the question directly! You could make a
> Workspace that forked things off without too much work, although there
> isn't such a thing built in AFAIK. Check out #evaluateSelection in
> ParagraphEditor to see where workspaces, etc., evaluate code. Of
> course there are twisty parts: e.g., you'd then have to manage
> stopping processes that ran too long, since they would still run in
> the background and use up resources.)
>
> Hope this helps,
> Benjamin Schroeder
>
> * At least I think this is right. For me, on Mac, it's command-period,
> so I think it's alt-period on XP. It could be ctrl-period if not.
>
> _______________________________________________
> Beginners mailing list
> [hidden email]
> http://lists.squeakfoundation.org/mailman/listinfo/beginners
>

_______________________________________________
Beginners mailing list
[hidden email]
http://lists.squeakfoundation.org/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: How to use development tools with a "consumer application VM image"

Jens Lincke
In reply to this post by Michael Vorburger-2
Michael Vorburger schrieb:
> How do you "peek" into it a Squeak image like the one Scratch
> distributes, so to see and learn from the Scratch classes and methods
> etc. and "hack" (in the best sense of the word) it?
>
>  
try to break something and get a debugger, this worked for me with
beta-versions of scratch under linux in which the dev tools were not
stripped out

- Jens -


_______________________________________________
Beginners mailing list
[hidden email]
http://lists.squeakfoundation.org/mailman/listinfo/beginners