There's always a slim chance I'm wrong, because I rely mostly on reading the macros, and not testing them, but from what I see, the macro doesn't "stall", it "completes." From what I see, your macro executes the second Select action only if the first one fails. (It's hard to be sure, because you didn't upload your macro, you only took a screenshot. So I can't see the flags on your actions.)
The reason it completes is that the first menu specified in your first action now exists. That's why you are seeing the menu.
If you want the second action to be executed, you have to do what your macro says, which is not to have the first folder exist.
I've attached the macro, and perhaps that will assist more in helping me resolve the issue with my Apple Mail "Move to…" macros.
The macro is basically a duplicate of others that are nearly identical, excepting the "Move to…" folder variable.
I wish I could post a movie of this odd new KM behavior of actually showing the macro at work, opening pull-down menus, but NOT moving the associated email message.
I should have been clear that NEITHER of the steps is successful, and the macro just sits there, and -- >50% of the time -- Apple Mail also starts misbehaving, and I have to force quit it.
I assumed that the last action result being OK referred to the email being successfully migrated to the designated folder, not whether the destination folder exists.
This is new KM behavior for me, and the only systemic variable that has changed is upgrading from Sonoma to Sequoia.
I'll close in saying that this suddenly showing the pull-down menu and hanging/stalling with the message/email being moved is COMPLETELY NEW BEHAVIOR for macros that have been operating fine (and in the background, with now menus shown, etcetera) for several years. zMove To Read RESURRECTED_250302 for KM Forum 20250306.kmmacros (3.8 KB)
I don't know what "just sits there" means. Did you open the debugger? Do you see which action the macro is sitting on?
Have you ever used the KM Debugger? Do you know how to use it to see what action is being executed? Do you know how to use the debugger to go step by step through a macro?
Well if Apple Mail is misbehaving, that could explain it. There's no way for KM to fix a badly behaving application. Did you check the Apple System log file to look for error messages regarding Apple Mail? Or did you check the KM Engine log file for clues?
Also, since you didn't say, I have to ask if you have rebooted recently? I've seen some reports that Sequoia has to be rebooted one MORE time than Apple says it does.
There's no way for me to replicate the behaviour of your macros because my Mail menu can't possibly be the same as yours, since I don't have the same folders as you.
I assume that the message is moved if you make the menu item selection manually?
Then start by taking one macro and resetting the menu item choices in that macro actions. If that doesn't help, delete the "Select Menu Item" actions and recreate them.
KM can select Mail menu items just fine in Sequoia, so this is something particular to either your update (eg a subtle change in menu structure from the previous version) or your system.
I'm grateful to Airy and Nige_S for their insights.
To Airy: yes, I have used the debugger, and it usually confirms what I am experiencing: the macro "hangs", "just sits there", "stalls" or whatever seemingly irritating description I use to describe the point of fail.
To Airy and Nige: I went for the President Musk option and defenestrated the macro. Perhaps it was carrying with it some bad juju from the macros it was borne of via duplication?
FYI: prior to recreating the macro from scratch, I reindexed Apple Mail and a host of other perfunctory directory structure and permissions housekeeping, rebooted from a FULL SHUT DOWN (which our engineers advise, as a RESTART apparently keeps debris "alive" in RAM).
Upon recreation of ostensibly the same macro (atttached), everything is back to behaving as it should (as much as I can tell).
I still "see" the macro steps taking place in the menu, etcetera, but they are "behind the scenes", and the pull-down menus no longer make unwanted appearances (quite a mess of cascading folders).
I reiterate my appreciation for the collective insights.
Alas, I am still experiencing the same issue where a KM "Move to…" macro in Sequoia causes the pull-down menu to appear; then the application just hangs.
This seems to me to be an issue that started around the time of Sonoma, but I can't be sure.
In any case, it is a drag as the "Move to…" macros I use all the time.
It may be that menus are being built on the fly and items aren't there to be selected until you open the parent. So try splitting your "Move" up, with a brief pause in-between:
Just going to note here that the Favorites Bar is a customizable, built-in way to easily file messages.
Counting from left to right in the Favorites Bar, mailboxes are automatically assigned Command-Control-[1 through 9] for filing messages. Of course the big limitation here is only nine mailboxes can get a keyboard shortcut.
I have been half-following this thread so, apologies if I there is something I am missing.
I have the below Macro that works every time for me to move selected message/messages to a certain mailbox.
I am on Keyboard Maestro 11.0.3 macOS Sequoia 15.4.1
The trick is that Mail builds the menus differently depending on how you are viewing your messages when the Macro is run. I include the two forms of the menu structure in the Macro and set each alternative version not to abort the Macro if it fails. The result is the correct form is used in each case and the Macro always moves the message/messages to the correct folder.
This is the Macro as I am using it. You would obviously change the mailbox and hotkey to what you want.
Break the action down -- does just
...cause a crash? Then add the "Move to" selection and test.
If it crashes when you add "Move to", do you have the same problem when accessing any other Message menu item? Try Message->Reply for a simple one, and Message->Flag->Orange for a sub-menu test.
Are you running any Mail extensions? Try turning them off.
Check for uniqueness -- for me, Mail will always select the first item in the menu hierarchy if there are two items with the same name, but that may not be true for you!
Try automating this with AppleScript or Automator, if only as a test -- that'll clue you in to whether this is a Mail problem or a KM-interaction issue.
NaOH, appreciate the suggestion for the "Favorites" option, but there are about 100 of these, so it could get a bit cumbersome.
And thank you, as well, Zabobon.
You'll see that your script is basically what I have (replaced the abort with an "if then…"), but the issue for me is that versus performing the macro "behind the scenes", my macro causes the layers of pull-down menus to appear, and Mac Mail freezes.
As I wrote, this is an issue that started to surface with Sequoia, methinks.
Likewise, Nige, thank you for suggesting breaking the macro down, and testing simple select menu functions.
I'm an Apple Script novice and haven't even tinkered with Apple Shortcuts, but this is a good opportunity to learn!
With these kind of issues where others are having success (i.e. I have Sequoia too and the Macro works fine for me) a good trouble-shooting method is to set up a temporary new user on your Mac, which only takes a few moments. Then to try the Macro in that new User Account. If all works as it should it suggests the Macro is fine and there is another issue unique to the original User Account.
@ Nige_S, thank you, but I've tried migrating the subfolder to the top of the tree as a standalone, and the issue persists with the pull-down menu freeze.
@ Zabobon, the fresh user is a method we always use for troubleshooting. In this case, however, it would mean migrating the entire Mail folder over to the new user to accurately reproduce the variables, and I unfortunately don't have the time to do that now.
It looks like it's Ye Olde Drag and Drop for the time being…
Wrong way round. You haven't said your exact structure but you have more than 100 mail folders to target. I'm suggesting that, if that's 100 at the same level of the hierarchy -- whatever point in the hierarchy that is -- you split them into 10 folders at that level with each folder containing 10 targets.
It shouldn't make a difference -- if you manually use the menus you should be able to do the same with the KM action. But I'm wondering if a "population pause" that isn't a problem for a slow user is a problem with fast KM/Mail menu interaction. Reducing the number of menu items at each level, at the expense of more levels, may solve the problem.
@Nige_S, as I wrote earlier, I don't know a way to post images of movies to the KM Forum to illustrate, but what I'm doing moving the destination Mac Mail folder OUT of the subfolders is basically simplifying the path, thinking that would make a difference with the failure of my "Move Message to…" KM Macro. It does not.
Also, this nesting is no more complicated than it has been for a long time, but this KM Macro behavior is a new one.
Perhaps I should do a complete remove and reinstall. Is there a KM Forum area that addresses this? I could not find anything excepting this:
I'm not talking about simplifying the path, but about reducing the number of menu items at each level of the path.
But you also said:
...which strongly suggests it's an OS and/or Mail version change that originally caused this, not KM's behaviour.
You've also fixed this before -- what changed in the last 6 weeks that's caused the problem to return?
Why?
Does the "Select or Show a Menu Item" action work in other apps? Does it work in other menus of the Mail app? If either of those is "Yes" then it is very unlikely to be a problem that'll be solved by reinstalling KM.
And since other people -- including me -- have no problems using this action to move mail in the latest versions of macOS and Mail, this looks specific to your setup. It might be your mail account -- you haven't said if the account is Gmail, Exchange, standard IMAP, POP... It might be the sheer number of menu items at that point in the selection process -- maybe even the combined character count of all those folder names! Perhaps latest OS/Mail update did subtle damage to Mail's indexes -- have you tried rebuilding them again?