The fix for this issue is now available in the latest update of InDesign – that is, InDesign 15.0.2.
Please update your InDesign application to get this fix.
Adobe InDesign team
An error occurred while saving the commentL. R. commented
Any document... Hit command Z and everything done is gone. All of it. Every time.
Turns out it also happens when you try to undo from the menu. I'm working on a 50 page document with character/paragraph styles, 78 linked images, master pages etc. at 3 am and didn't need this headache. It's bad enough that InDesign crashes to force updates.
It doesn't take you back to your last save. I've been saving every time I make a change and I still needed to hit undo and it reverted the document back to a point that I can't put my finger on.
The icing on the cake is now that I've been saving and not undoing I got this error: Adobe Indesign is shutting down. A serious error was detected. Please restart Indesign etc.