Random storage files converted to links, annotations lost
Hi,
To sync my library across multiple computers, I use the zotero sync function for everything except the files, which I manually sync via git.
Today when I booted zotero on a machine I hadn’t used in some time, it decided to remove some seemingly random pdf files from the storage and convert them into links instead. This is a real pain because I do need the files to stay in the storage for git to share them, and most important of all, I have lost all annotations in the process.
Is it possible to correct the damage? That is:
-Get the pdfs back in the storage in a batch. I do have a backup of the storage folder through git but zotero seems to have lost the pointers to the files.
-Restore the annotations. If this is impossible I want a way to store the annotations in separate files that I can backup via git so I don’t lose any in the future.
Finally, if anyone has an idea of where the issue comes from and how to prevent it that would be great.
To sync my library across multiple computers, I use the zotero sync function for everything except the files, which I manually sync via git.
Today when I booted zotero on a machine I hadn’t used in some time, it decided to remove some seemingly random pdf files from the storage and convert them into links instead. This is a real pain because I do need the files to stay in the storage for git to share them, and most important of all, I have lost all annotations in the process.
Is it possible to correct the damage? That is:
-Get the pdfs back in the storage in a batch. I do have a backup of the storage folder through git but zotero seems to have lost the pointers to the files.
-Restore the annotations. If this is impossible I want a way to store the annotations in separate files that I can backup via git so I don’t lose any in the future.
Finally, if anyone has an idea of where the issue comes from and how to prevent it that would be great.
You can convert linked files to stored files via Tools → Manage Attachments → Convert Linked Files to Stored Files, but beyond that I'm afraid you're on your own. Your best bet is probably to restore from a backup from before you did this.
So lost Zotero-added (not externally-added) annotations would seem to suggest a Zotero data-related issue not a PDF file-related issue would it not ?
How did you "remove some ... pdf files from the [Zotero local ?] storage and convert them into links" ? Where is your Zotero data directory located ? How did the lost annotations issue actually show itself ?
@plafourc should restore from a backup of their entire data directory from before this happened, which will restore both the database and the stored files, and then use Replace Online Library to overwrite the online library.
https://www.zotero.org/support/zotero_data#restoring_your_zotero_data_from_a_backup_and_overwriting_synced_changes
I do have zotfile in my system, which might be the issue.
As for the annotations it looks like the database items corresponding to the stored pdf files have been removed, and fresh items with links to pdf files were created instead. Hence the vanishing of notes I guess.
For example, if a user deletes a PDF attachment (stored or linked; and from within Zotero or outside Zotero) that had annotations, and then re-adds the PDF again (stored or linked), can the annotations persist, or are they lost ?