The Omni Group Forums

The Omni Group Forums (http://forums.omnigroup.com/index.php)
-   OmniFocus 1 for Mac (http://forums.omnigroup.com/forumdisplay.php?f=38)
-   -   Automator can't open OF [Bug: please email support ninjas] (http://forums.omnigroup.com/showthread.php?t=12991)

Craig 2007-11-20 08:45 PM

Automator can't open OF [Bug: please email support ninjas]
 
Both of those work for me when run from Script Editor.

However, both of them fail for me when run from a "Run AppleScript" step in an Automator workflow. ("OmniFocus got an error: Some parameter wasn't understood.")

Tim Wood 2007-11-23 10:07 PM

[QUOTE=Craig;25446]However, both of them fail for me when run from a "Run AppleScript" step in an Automator workflow. ("OmniFocus got an error: Some parameter wasn't understood.")[/QUOTE]

This works fine for me under Automator on both 10.4 and 10.5. Could you try running OmniFocus from Terminal with something like this (assuming you are using bash or zsh):

AEDebugReceives=1 /path/to/OmniFocus.app/Contents/MacOS/OmniFocus

and then invoke your (minimal) script. This will spew a ton of output, so just do the 'activate' bit :)

Craig 2007-11-24 08:12 AM

[QUOTE=Tim Wood;25840]This works fine for me under Automator on both 10.4 and 10.5. Could you try running OmniFocus from Terminal with something like this (assuming you are using bash or zsh):

AEDebugReceives=1 /path/to/OmniFocus.app/Contents/MacOS/OmniFocus

and then invoke your (minimal) script. This will spew a ton of output, so just do the 'activate' bit :)[/QUOTE]

Both now seem to be working for me in 95008. Let me know if that output would be useful to you regardless.

Craig 2007-11-28 03:12 PM

[QUOTE=Craig;25863]Both now seem to be working for me in 95008. Let me know if that output would be useful to you regardless.[/QUOTE]

Okay, I spoke too soon, and I do have that output for you.

Note that the simple activate script wasn't triggering the workflow crash, but this is the script that was:

[CODE]tell application "iCal" to quit
tell application "OmniFocus"
activate
tell default document
tell front document window
set perspective name to "starting soon"
end tell
end tell
end tell
tell application "end of the day" to activate[/CODE]

Here's what results from your procedure when the workflow containing this script is run (and crashes):

[CODE]user$ AEDebugReceives=1 /Applications/OmniFocus.app/Contents/MacOS/OmniFocus
OCCCrashCatcher: Not enabling crash catching since we're connected to a tty (and thus presumably in gdb)
2007-11-28 17:07:09.382 OmniFocus[1768] linkPath /Users/user/Library/Mail/Bundles/OmniMailMessageServiceEnabler.mailbundle
2007-11-28 17:07:09.383 OmniFocus[1768] bundledPath /Applications/OmniFocus.app/Contents/Resources/OmniMailMessageServiceEnabler.mailbundle
2007-11-28 17:07:09.383 OmniFocus[1768] doesExist = 0, shouldExist = 0
AE2000 (1768): Received an event:
------oo start of event oo------
{ 1 } 'aevt': ascr/gdte (ppc ){
return id: 113967135 (0x6cb001f)
transaction id: 0 (0x0)
interaction level: 64 (0x40)
reply required: 1 (0x1)
remote: 0 (0x0)
target:
{ 1 } 'psn ': 8 bytes {
{ 0x0, 0x13a0001 } (end of the day)
}
optional attributes:
< empty record >
event data:
{ 1 } 'aevt': - 1 items {
key '----' -
{ 1 } 'long': 4 bytes {
0 (0x0)
}
}
}

------oo end of event oo------
2007-11-28 17:07:25.779 OmniFocus[1768] .sdef warning for part of complex type 'color | text | file | point | real | integer | boolean | point | missing value' used in suite 'OmniStyle Scripting': 'missing value' is not a valid type name.
AE2000 (1768): Received an event:
------oo start of event oo------
{ 1 } 'aevt': misc/actv (ppc ){
return id: 113967139 (0x6cb0023)
transaction id: 0 (0x0)
interaction level: 96 (0x60)
reply required: 1 (0x1)
remote: 0 (0x0)
target:
{ 1 } 'psn ': 8 bytes {
{ 0x0, 0x13a0001 } (end of the day)
}
optional attributes:
{ 1 } 'reco': - 2 items {
key 'subj' -
{ -1 } 'null': null descriptor
key 'csig' -
{ 1 } 'magn': 4 bytes {
65536l (0x10000)
}
}

event data:
{ 1 } 'aevt': - 0 items {
}
}

------oo end of event oo------[/CODE]

Hope that helps your bug-hunting!

Craig 2008-02-08 05:52 AM

You're in good company:
[url]http://forums.omnigroup.com/showthread.php?t=5141[/url]
Maybe this thread will provoke an update on this issue from Omni.

Craig 2008-02-10 09:20 AM

Not fixed for me. In 97569, this script in an Automator "Run Applescript" action
[CODE]tell application "OmniFocus"
activate
tell default document
tell front document window
set perspective name to "out of office"
end tell
end tell
end tell[/CODE]
returns this error:
[QUOTE]OmniFocus got an error: Some parameter is missing for activate.
[/QUOTE]
(Same error if I make the activate command its own tell line, too.)

RobTrew 2008-02-10 01:14 PM

Probably worth recompiling the text.

Try going back to fresh plain text with the extension [B].applescript[/B] rather than a compiled script with the [B].scpt[/B] extension.

Craig 2008-02-10 09:33 PM

[QUOTE=RobTrew;32765]Probably worth recompiling the text.

Try going back to fresh plain text with the extension [B].applescript[/B] rather than a compiled script with the [B].scpt[/B] extension.[/QUOTE]

I'm not sure I follow you here. I'm not using either extension, as this script exists within an Automator routine...

RobTrew 2008-02-11 06:59 AM

Is this an Applescript Automator action which you are developing through Xcode ?

It would probably be worth testing the code from a text (.applescript) file, or rebuilding the Xcode project from scratch, copying the program text in from text files.

Craig 2008-02-11 07:08 AM

No Xcode, I'm merely using Automator.app, dragging over a "Run Applescript" action to the workflow, and typing the script into the box in the action. Then hitting the play button.


All times are GMT -8. The time now is 11:06 AM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2021, vBulletin Solutions, Inc.