Loop in unique Action Macro

Here is this strange macro:

Context Safari loop😰.kmmacros (2.4 KB)

Kind of conflict between triggers and action?

Some highlight needed...


I’m certainly no expert here, but my understanding is that even after Safari (or any browser) is activated (including a new window title), the page may still take some time to finish loading.

I have personally seen this with just a manual click on a link outside of a browser (like in an email) and observe the process of browser launch, and then some time for everything on the page to be fully displayed.

Hope this helps . . .

Loops occurred when Safari is minimized.

The trouble is when the triggers fire, the macro never finish... despite the setting of Wait For Safari to Finish Loading is:

So an increasing number of instances is running :flushed:, till I cancel and disable this macro.

Thanks JMichael for your help and your code :slight_smile:

This works for me, running Keyboard Maestro 7.2.1 (7.2.1) on macOS 10.10.5:
Also works on Keyboard Maestro 7.2.1 (7.2.1) on macOS 10.11.4

EDIT: 2016-08-28 20:37 CT (Sun)

  • Updated Macro to add Trigger info

###MACRO:   Safari Launch TEST

~~~ VER: 1.1    2016-08-28 ~~~

Safari Launch TEST.kmmacros (7.6 KB)



PURPOSE: Test/Example of Trigger on Safari

NOTICE: This Macro is uploaded in "Disabled" Mode.


  • I have noticed that when Safari is activated, you will get two triggers:
    1. One for Safari activation
    2. One for Window Title change

So, I added Trigger info to the display.

The "IF/THEN" Action is very important, otherwise this macro will continue to run when a window title anywhere changes.

1 Like

I can confirm: it is the solution :+1: Thank you for testing and your help.

Nevertheless, I don’t really understand why Safari cannot finish loading when it is not at front ??? (bug?)

Post above updated with macro file.

Just uploaded update.

What would be the point of that macro? Unless there are actions after the Wait, it’s not going to do anything.

The Wait tests, among other things, the state of the Stop menu, which Safari probably does not update in the background.

I assumed there were Actions after the Wait in his production Macro, and that he just uploaded a brief macro to illustrate the issue.

IAC, that’s why I added a “Display” Action after the wait so we could see what’s happening.

The question/issue now appears to be solved.

@JMichaelTX Correct

@JMichaelTX ??? because: