Reproducible bug w/Typinator + clipboard history switcher

Okay, if I have rich text as the top entry of the "clipboard history switcher"....and then I execute a typinator expansion (plain text)...then that same entry in the switcher APPEARS to be the same (the rich text), but when I paste it, I get just the Typinator expansion (unrelated plain text).

So the top item below (sorry for pixelation but has patient information):

...comes out as the typinator expansion I executed before pasting:

database from this stay

Same if I move it around the history or "Set Clipboard to" it. HOWEVER, if I "Set Clipboard to plain text," I do get the underlying plain text (so the data is there).

Also, I can verify that the rich text clipboard pastes CORRECTLY, and then do a Typinator expansion, and then I'm at the bug situation!

I can do a video if needed...

My guess would be that Typinator is setting the transient flavor on the clipboard, but then not actually setting the clipboard back to the value it was afterwards.

You could turn off transient clipboard support by using the Terminal command:

defaults write com.stairways.keyboardmaestro.engine TransientClipboardFlavors 'KM never match anything KM'

And then relaunch the Keyboard Maestro Engine.

@ajg23: After a clipboard-based expansion, Typinator tries to restore the clipboard “just in time”. It seems that Typinator does not correctly detect that the clipboard is needed in this situation.
Can you please tell me which version of Typinator this is?
I would also like to know how exactly you insert the clipboard entry from Keyboard Maestro: Do you use only keyboard commands for invoking and navigation? Or do you click to select the desired item from the clipboard history?
Please also tell us in which target application this happens. Can you reproduce the problem in other applications, such as TextEdit?

1 Like

Thanks Peter and Gue!

Gue, re your questions:

  • Typinator is the newest beta: 7.3 (27395).
  • it happens whether I use Cmd+V or double-click the item in the clipboard history switcher
  • ah-HA! It happens only in Word! But I’m using newest “Office Insider Fast” beta of Word too: 16.7 (171008). I can’t believe I didn’t test that myself! :flushed:


  • it only happens in Word (beta), as above! But the fact that Keyboard Maestro is showing the proper text in the switcher but then not pasting it is suspicious for something going on with KM, too?
  • turning off transient clipboard support (and restarting engine) didn’t fix it–still happens (again, in Word, in the beta). How do I turn it back on?

Thanks all for input!

PS: So Word’s causing the problem again :roll_eyes:. But I use the hell out of so much Word stuff (including tons of VBA code) I can’t just switch to something else :stuck_out_tongue: (And I’m using the newest beta because it has a reasonable VBA editor!)

defaults delete com.stairways.keyboardmaestro.engine TransientClipboardFlavors

Not really, it just means Keyboard Maestro is out of sync with the current system clipboard, so the system clipboard has been changed without Keyboard Maestro recording it.

But if I tell KM to set the current clipboard to it, it still doesn't work...Seems like it should be successful if nothing wrong on KM's side?...

If Keyboard Maestro already thinks that that is the current clipboard, then it wont do anything.

You could try:

Set Clipboard to text "whatever"
Set Clipboard to desired entry

See if that works.

No, that still doesn’t work: it again LOOKS like the clipboard is set to the original formatted text in the clipboard switcher, but if I paste, it puts the expansion text–just verified [again, this is all in word, and all formatted text]. That’s why I thought bug in km.

If it only happens in Word, it is probably also related to Word caching the clipboard.

It appears that Word has changed the flavors it uses for bookmarks, which may or may not be related to this.

If you turn on Show in Documents: Bookmarks in the Word View preferences, you can see all sorts of crap happening every time you copy something.

If you run this in the Terminal:

defaults write com.stairways.keyboardmaestro.engine ExtraIgnoredClipboardFlavors 'dyn.ah62d4qmxhk4d425try1g44pdsm11g55gsu1e82xnqzv1kxdmr3zu|dyn.ah62d4qmxhk4d425try1g44pdsm11g55gsu1e24psrq0zg55zsmv0n'

And then relaunch the Keyboard Maestro Engine, that should stop Keyboard Maestro from reading the bookmark flavors, which will resolve the weird behaviour in Word - and may or may not resolve the Typinator issue.

1 Like

God bless you Peter, that did it!

Thank you for being able to stay a step ahead of Microsoft’s bugs! :stuck_out_tongue:

Sigh, CORRECTION: it only SEEMED to be fixed because I turned Typinator’s “quick expansion” setting back on–this is the preferred state (I’d turned off as part of troubleshooting). Thus, Typinator was no longer using the clipboard to expand short snippets, so the bug wasn’t being triggered.

So STILL, if formatted text from Word is on the clipboard, and I replace the clipboard it with any other text (plain or formatted), and then I try to paste in the original text from the clipboard history, I get the second clipboard contents–even though what I’m clicking in the history is a picture of the original formatted text!

This happens in all of these cases:

  • copying from Word
  • having Typinator expand a rich text item
  • having Typinator expand plain text but using the clipboard (ie, with “quick expansion” turned off)
  • copying explicitly plain text from Word’s “search bar”

So shall I set that Keyboard Maestro setting back to the prior setting in terminal?

And any specific I should tell the Microsoft Word folks about fixing this? (I’m giving feedback for their betas).


Hey Peter, wanted to make sure you saw these specific questions:

No. Thos changes will be built in to the next version. You can delete them if you want, and you should after the next version, but they are generally desirable currently.

I'm not sure whether it is a bug or intended that they changed the clipboard flavors from

to their dynamic equivalents:


It may be a bug, or they may not care.

Sorry, I should have added: What is definitely a bug is adding a bookmark just because some other application reads their clipboard flavors. That is without a doubt a bug, but they may not care about that either.

Well, I have extremely surprising news for you: the erroneous behavior doesn’t happen anymore in the newest beta of Word (16.7, build 171029)! We’ll see if it returns in another build :stuck_out_tongue:

Please tell me specifically how to reset that setting–want to test to see whether still works if KM is in original state…


Remove it with:

defaults delete com.stairways.keyboardmaestro.engine ExtraIgnoredClipboardFlavors

Then relaunch the Keyboard Maestro Engine.