HTML prompt WebKitDeveloperExtras (Inspect) working in KM 10?

Is this working for others ? I may be getting something wrong.

I want to be able to control-click elements in a KM HTML custom prompt, and choose Inspect, as described in the Wiki:

action:Custom HTML Prompt [Keyboard Maestro Wiki]


If you want to be able to inspect your HTML live, you can use the Terminal command:

defaults write com.stairways.keyboardmaestro.engine WebKitDeveloperExtras TRUE


And the system prompt confirms for me that I have set that option to TRUE:

prompt> defaults read com.stairways.keyboardmaestro.engine WebKitDeveloperExtras
zsh> TRUE

but the contextual menu offered when HTML elements in the custom prompt are clicked does not yet include Inspect.

Any thoughts ?

The context is:

  • macOs Big Sur 11.6.1
  • Keyboard Maestro Version 10.0.2

Screenshot 2021-12-10 at 11.59.40


For reference, if I open the same HTML in Safari, the contextual menu looks like this (includes Inspect Element):

Screenshot 2021-12-10 at 12.19.42

Forgive me – this was already solved elsewhere.

The trick is to reboot the Keyboard Maestro Engine.

(I had only quit and restarted the KM app, which is, of course, not the same thing)

All good now.

( Perhaps worth a small addition to that section of the Wiki, reminding us to restart the Keyboard Maestro Engine ?)

Screenshot 2021-12-10 at 12.39.52

Not so fast ...

I seem to have missed another point, and I think the Wiki may need a second update ...

It turns out that prefixing TRUE with -bool in the command line incantation makes a difference – at least in my default Big Sur shell, which is zsh:

> echo $0
> -zsh

(If I repeat the exercise using the incantation shown on the Wiki, which lacks the -bool prefix, Inspect Element is still suppressed after a KM Engine restart)

The current draft of the wiki doesn't use the -bool prefix which @peternlewis shows in his response to Dan (linked above)


Summary

Two edits may be needed to the Inspect Element section of:
action:Custom HTML Prompt [Keyboard Maestro Wiki]

  • It seems that the command line incantation needs to be changed, inserting -bool before TRUE (to specify a value of the right type).
  • Users probably need to be reminded to use File > Quit Engine and then restart KM.

It does in the Preferences, but the one in the action does not include the -bool as it should, otherwise the field will be set to a string (maybe).