AppleScript Execution Error: File Keyboard Maestro Engine Wasn't Found

Hello!

Unexpectedly stopped working with the following error: File keyboard maestro engine wasn't found.

Could someone explain what went wrong?

Screenshot 2022-04-06 at 03.05.22

Thanks in advance.

Only if you let them see the macro :slight_smile:

If you are just using Script Debugger to evaluate some AppleScript code which references application "Keyboard Maestro Engine", then, inter alia you would probably need to specify macOS version etc.

This is working here:

tell application "Keyboard Maestro Engine"
	count of variables
end tell

on macOS 11.6.5 with an old version of Script Debugger (7.0.13)

Hey @kreal,

What have you done to troubleshoot?

  1. Restart the Keyboard Maestro Engine & the Keyboard Maestro Editor.
  2. Reboot.

Did you do anything to your system that might have been the cause of the problem?

A recent upgrade of macOS Monterey (12.3) caused a problem with Finder scripting, but that was fixed by v 12.3.1.

Error code 43 stands for an error that happens when your Mac can't locate the file in question and thus can't complete the requested action, e.g. moving the file to Trash, copying it, or moving it to a different folder.”

As @ComplexPoint says – we can't give any sort of responsible answer without knowing what you're doing – on what version of macOS – and with what version of Keyboard Maestro.

So please elucidate.

-Chris

Hey @ComplexPoint

I have reinstalled KM but the error is still there.

The script above returns correct amount of variables

I have some scripts in script libraries folder that are used in the main script that runs using KM.

Running the applescript directly from Script Editor or Debugger throws the missing file error.

I even tried to export macros to a different pc and it still doesn't work, so I have no idea on how to fix it.

I am using KM 9.1 & MacOS 11.5

Hey, Chris!

I am not sure what I did, was working on scripts, moving files around and this happened.

Rebooting, reinstalling KM doesn't help.

It would help to see one that that trips the error.

I have finally figured out where the problem was:

The code caused the error was:

tell script "Some Script" to set theResult to SomeHandler("Parameter1", "Parameter2", "Parameter3")

And it started to work after a single run of the same code but without the theResult variable

tell script "Some Script" to SomeHandler("Parameter1", "Parameter2", "Parameter3")

I have no idea why that happened.