Script Debugger scripting "open .. recovering text true" problem

(Kerm Steffenhagen) #1

I have been able to use the recover script feature (File->Recover Damaged Script …) to open compiled scripts that have been messed up by replacing “SatImage” with app “SatimageOSAX”; this allows me to get clean text (without chevrons) to patch up with new “use” and “tell” statements.

I am trying to ‘script’ this action, with a script that will open (recover) the file as text and then save it as text (.applescript). I am having trouble with SD7’s “open” command when I add the “recovering text” option.

open alias "HighSierraHD:Users:____:Library:Scripts:Applications:InDesign:openWithStamp4Gen.scpt" showing script source with recovering text*

Error: the Apple Event handler failed (errAEEventFailed:-10000)

Note that “openWithStamp4Gen.scpt” opens as text with the (File->Recover Damaged Script …) menu command, and opens (with chevrons) without the “recovery text” option; but adding the “recovery text” option produces the error.

It this a bug?

0 Likes

(Mark Alldritt) #2

Yes, this is a bug.

You reported this at a perfect moment as I’m preparing the Script Debugger 7.0.8 maintenance release and I’m able to get a fix for this issue into that version of Script Debugger. Script Debugger 7.0.8 will be released shortly.

0 Likes

(Mark Alldritt) #3

I’ll add that you should be able to add the use application "SatimageOSAX" statement to the beginning of your scripts and AppleScript will then convert the chevron syntax commands back into human readable form when you compile.

0 Likes

(Kerm Steffenhagen) #4

Looking forward to the 7.0.8 release - thanks…

0 Likes

(Kerm Steffenhagen) #5

RE: Adding "use application “SatimageOSAX” and re-compile …

This works only if this change does not create terminology conflicts … then the compile fails … and you have to work with chevrons and misleading errors. Not un-doable, but using recover has proven easier.

0 Likes