KM Editor Pauses Sometimes

Here's an attempt. Let me know if I got it in time:

dump.txt.zip (43.3 KB)

Thanks.

No, that is a sample of the Keyboard Maestro Engine, not the editor.

Select the Keyboard Maestro editor in Activity Monitor.

Dangit! I'll try again.

OK, try this one: Sample of Keyboard Maestro.zip (83.8 KB)

I think it's quite possible that it waited to get the sample until the editor quit pausing. I pressed the hotkey in plenty of time, and if memory serves, the window popped up while KME was still paused, but it didn't display the result until the editor continued.

On the other hand, the timing might have been coincidental.

It looks like it was trying to update the menus (possibly in result of a keystroke that could have been a menu key, which is probably any keystroke with a modifier, especially command, but possibly option or control.

Keyboard Maestro was stuck filling the share menu, which means it was trying to get the actions as an image, which is really excessive behaviour at that point in time. It was then stuck rendering the PDF of the actions, probably deep in the PDF rendering engine.

I will take a look at this and see if I can resolve it to avoid or mitigate the issue (hopefully without having to remove the share menu from the File menu, though that is one possible solution).

Thanks, Peter! It's not the end of the world at all, so don't go crazy trying to solve it.

But I have a question: I've always suspected this has something to do with large icons that I didn't shrink down before pasting them into a KM macro. Do you think this could contribute somehow?

And if so, do you have any ideas how to find the macros with large icons? You know I don't mind getting my hands dirty. I've tried lots of things with JXA but since icons are stored differently, I haven't quite figured out how to find their sizes.

Just a thought.

Possibly, but probably not.

Keyboard Maestro has no way to get the size of the macros. But the XML for a macro will be a good indication. So basically you could just go through all the macros and get the XML for each (which should all be easily doable with AppleScript) and sort by size.

Thanks! I hadn't thought of using the size of the entire macro, but that's a good idea.

By the way, the problem was happening constantly yesterday. I was working on some macros for the Palette I use for Atom. It has 61 macros it it, and none of them are in the menu. A lot of them have icons.

But I was also working on some other macros at the time, so I can't say for sure if the size of the palette had anything to do with it. And of course, I can't duplicate the problem now, so who knows.

Basically, any time you access the menus (which includes things like ⌘C, or any other command key), the menus have to be filled out. Filling out the Share menu means getting the image of the selection. Depending on what is selected, that could mean getting the image of the entire macro you are editing, including all the actions. That can be quite slow.

Basically, imagine you are doing Copy ➤ Copy as Image every time you hit a command key.

If my guess is right, this should be resolved in v9.

Thanks, Peter.

There are some aspects of being a professional developer that I don't miss in the slightest. On the other hand, once I release a YouTube video, I can't release updates for it to fix anything I left out or stated incorrectly. So I guess it goes both ways. :smile: