Re: AppleScript crashes constantly
Re: AppleScript crashes constantly
- Subject: Re: AppleScript crashes constantly
- From: Emmanuel <email@hidden>
- Date: Fri, 9 Feb 2001 17:52:12 +0100
At 14:15 +0100 9/02/01, Wim Melis wrote:
>
Any ideas as to what might be causing this? Is there anything standard
>
that is known to cause memory leaks?
I don't intend any offense to anyone here, but many features of AppleScript
cause memory leaks. We observe carefully memory leaks here because our
clients would run our systems on manufacturing lines in plants, 24 hours a
day and 365 days a year.
What I would do as a first, easy, step would be: use the "Check Memory"
dialog of Smile. It has a "watch for leaks" checkbox. Then, run your script
from Smile. The more you'll be able to make it run piece by piece (in the
Text Windows of Smile), the more easily you will sort out where the leak
lies.
As a remark intended to be relevant to your case, our experience has led us
to systematically do any text processing, parsing etc. in Smile instead of
using basic AppleScript. In short, we use Smile's text windows instead of
AppleScript variables.
For instance, "tell app "Smile" to get paragraph 3000 of window 1" is safe
and reliable, whereas I would not swear that getting the 3000th paragraph
of an AppleScript variable containing several Megs of text would be. I
mean, maybe it is, maybe not.
HTH
Emmanuel