Hideous Bug (I think)

I’ve been revising my book and getting all sorts of mysterious reversions, where fixes I’m making keep “reverting” as if I hadn’t done anything. I think I may have figured out how to repro the bug.

I was getting this under 2.0 v6076 and still get it under v6218.

If I open a chapter as a “scrivening” (this is my normal work flow), by clicking the folder/chapter in the binder (multi view is selected so all the files/scenes under the folder auto generate together into a meta doc).

Then I DELETE SOME TEXT, but DO NOT TYPE ANY TEXT

The files are NOT SAVED. They are changed in the cache in memory, but even if you hit command-S, or quit, the file was never saved and the deletion does not happen. When you reopen, presto, reversion!

If you don’t use a scrivening (click the scene directly in the binder) this doesn’t seem to happen (the file saves).

If you type anything in, like hit spacebar and then backspace to add a char and remove it. Then the file is saved.

It seems that the scrivening dirty file detection or similar isn’t triggering off pure deletions! I’ve just noticed this recently because i’ve been putting in line edits from people that mostly have deletions. It took me awhile to track down the extra reproduction steps.

This is really scary!

I suspect this is a bug that’s already been reported, which Keith has fixed for 2.0.1 (due out shortly):

https://forum.literatureandlatte.com/t/scrivenings-mode-deleted-text-reappears-on-relaunch/9402/1
and
https://forum.literatureandlatte.com/t/text-that-just-wont-delete-scrivener-2-0/9735/1

The workaround in the meanwhile is presumably just to do your deletions in single-document mode (perhaps work with split pane, one editor with the Scrivenings and one with the single documents?), but it should all be fixed up soon–Keith may get the update out by the end of the week.

I’ll be careful in the meantime now that I know how to work around it. Look forward to the fix. This was driving me nuts for the last week or two, all these deletions magically reappearing – sometimes.