I only skimmed this thread so I may have missed it if this was already reported.
I think I found a bug. Here's all the steps I remember making:
1. I downloaded and installed the portable version. I exited my main Calibre and opened the beta version.
2. I changed the UI font to Calibri (11pt) and restarted.
3. I opened Quick Start guide in the viewer.
4. I went to the viewer settings and enabled the toolbar.
5. I changed the viewer settings to not save bookmarks in the file itself.
6. I used the toolbar button to changed the viewer colour scheme to white. (I use dark mode in my main Calibre, and the environment variable carried over to portable version.)
7. I selected the "Highlight" button on the toolbar. I highlighted some of the text, changed its colour to pink, added a note, and saved the annotation:
8. I used the toolbar button to change viewer colour scheme to Sepia Light. The annotation disappeared.
They didn't come back when I changed the scheme back, but they did come back when I restarted.
Enhancement idea: For those who switch between schemes, perhaps an option to select an alt highlight colour for the dark modes (black and sepia dark) would be an idea. Some of them I had difficulty viewing on certain schemes. Not sure what to do about custom schemes though.
Question: I don't use embedded bookmarks. If I test some books from my main Calibre library by opening them directly in the viewer (skipping the library), will I be able to preserve any annotations by later copying the json files from viewer/annot/ over to my main Calibre's application data folder?