Re: crash when getting AppleScript dictionary
Re: crash when getting AppleScript dictionary
- Subject: Re: crash when getting AppleScript dictionary
- From: Don Briggs <email@hidden>
- Date: Thu, 6 Nov 2003 08:30:54 -0800
Hi, Christopher
I suggest to visit
http://homepage.mac.com/donbriggs/
and download Suite Modeler
suite_modeler_2.2.dmg
(use the 2.2 version for Panther)
In free Demo mode, it can load your pair of plists.
You can browse your suite as a tree of table views.
The coloration of the cells will help show you what's default, OK, and
bogus.
(The coloration is controlled in the preferences panel.)
Use the "Find" panel to diagnose your suite.
There's on-line help in the app and some examples on the same page.
All best,
Don
On Nov 6, 2003, at 1:30 AM, Christopher Corbell wrote:
Thanks to those who answered my previous script question -
however I haven't quite gotten it working because I'm
now seeing a crash of my app whenever Script Editor tries
to open its dictionary. I'm in XCode / Panther /
Obj-C Cocoa.
Has anyone seen this before? To simplify things I
stripped everything out of the suite definition and
terminology except for the suite AE type and name.
(According to the documentation that shipped with XCode
GM, every field except for "Name" and "AppleEventCode"
is optional in the suite definition.)
When I try to open the dictionary for my minimally-scriptable
Cocoa app, I get the console message:
"No readable name in dictionary"
followed by an EXC_BAD_ACCESS exception. All of this
happens in NSScriptSuiteRegistry calls; here's the relevant
part of the crash log:
Thread 0 Crashed:
#0 0x901911c4 in CFRetain (CFRetain + 32)
#1 0x901acec4 in CFArrayCreate (CFArrayCreate + 324)
#2 0x90ae3424 in readableNameArray (readableNameArray + 160)
#3 0x90adecd0 in -[NSScriptCommandDescription
_readCommand:dataStream:] (-[NSScriptCommandDescription
_readCommand:dataStream:] + 992)
#4 0x90ae1194 in -[NSScriptSuiteRegistry
_readCommands:dataStream:suiteID:] (-[NSScriptSuiteRegistry
_readCommands:dataStream:suiteID:] + 128)
#5 0x90ae1390 in -[NSScriptSuiteRegistry _readSuites:dataStream:]
(-[NSScriptSuiteRegistry _readSuites:dataStream:] + 428)
#6 0x90ae194c in -[NSScriptSuiteRegistry aeteResource:]
(-[NSScriptSuiteRegistry aeteResource:] + 224)
If I completely remove the script suite and terminology files
from my app bundle, the crash does not happen and I see the
default Cocoa dictionary (core + text). I've tried re-creating
my property lists from scratch, adding or removing items based
on examples in other apps, etc.
Can anyone suggest what in the world's going on here?
Even if I am missing some required field in the script suite
or terminology, I would hope that we could have graceful
failure from the Cocoa AppleScript code rather than a nasty
crash. Also, I checked my more complete suite (with just 1
class - the app - and 1 custom command, supported by the app)
in Suite Modeler demo, and didn't see any warnings - yet it
crashed as well...
Thanks for any help,
Christopher
=============================
Cider Factory Software, Inc.
http://www.cidersoftware.com
=============================
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.