Undeleted PDFs

Updating the Zotero 'storage’ subdirectory (Firefox and Standalone)

If I delete a zotero item, I have noticed that the associated pdf (and containing folder) stored in the 'storage' subdirectory in the 'zotero' directory (FireFox) is not deleted.

These items remain after closing, after emptying trash, after a month of usage, … the furtherest back I can reasonably trust my knowledge of deleting material from Zotero. I use Houndahspot to find the remainder items. Using search in Zotero Standalone or the Firefox version does not indicate their presence just indicates the false picture of a nicely curated subdirectory.

Any thoughts on how to update the 'storage' subdirectory? Please share,

I used this as source info: https://www.zotero.org/support/zotero_data

Past reporting of remainder pdfs:

https://forums.zotero.org/discussion/9481/20b74-not-deleted-pdf-attachments-filesystem/
  • the only confirmed past issue of this (the one you link to) was due to read-only files (which obviously Zotero can't delete). If that's not the case for your left-over items, first thing would be to see if you can replicate this. I.e. locate the storage location of an item's attachment, delete the item (via right-click -->Move-item to trash - remember that removing an item from a collection doesn't delete it), empty the Zotero Trash and see if the attachment is deleted.
    If it's not, submit a debug ID for the whole operation:
    https://www.zotero.org/support/debug_output

    The only way to remove orphaned files that I'm aware of is mronkko's Perl script in this thread:
    https://forums.zotero.org/discussion/9091/orphaned-attachment-files/
  • Thanks for the guidance, ... will do,

    Read|Write access on the files,
  • Duplication, Zotero Database, Zotfile

    I feel I am still seeing a version of this issue, here is my latest description,

    I have a database in Firefox:

    /Users/moses/Library/Application Support/Firefox/Profiles/qlcdz25g.default/zotero/storage/3NCCQ756/SomeFile.pdf

    I have used Zotfile and have that same PDF, in:

    /Users/moses/Dropbox/Zotfile_Zotero/Sociology\ Compass/SomeFile.pdf

    ... and in a folder I created in Zotero: BloodPressure, for articles, focused on BP, again the same PDF

    /Users/moses/Dropbox/Zotfile_Zotero/BloodPressure/SomeFile.pdf

    I am going to clean this up. I am trying to figure out why this PDF remains in the Firefox database after moving the entry to the folder BloodPressure, and why after using Management Attachment>Rename Attachments, the attachments were renamed and also created /Sociology\ Compass/SomeFile.pdf,

    Of course, I dislike this mess and I am wondering the extent of such repetitions throughout the database. Any suggestions for what is happening welcome,
  • Not sure this is the same issue now that ZotFile is part of the story.
    What exactly are your renaming rules in ZotFile?

    And are you still seeing the PDF in storage/3NCCQ756 after using rename attachment?
    Also, do you have, anywhere in your library, a collection called Sociology Compass?
  • edited April 13, 2016
    * Thank you for replying,
    * What exactly are your renaming rules in ZotFile? I am not using Zotero(Z) to rename, have selected some of the Additional Settings: Replace blanks, Max. Length, Max author: 1, et al, https://www.evernote.com/l/AAf7DZwF1ElFCL4sGVHzI5SAY5JSImzOt2U

    * And are you still seeing the PDF in storage/3NCCQ756 after using rename attachment? Yes, and this is why I think it a similar issue,

    * Also, do you have, anywhere in your library, a collection called Sociology Compass? Of course, I am showing the filepath; the Sociology Compass folder was created upon Rename. Or is your "library" a reference to the Z database, if the latter I do not know, HoudaSpot only finds it in the Zotfile folder, but my experience is the Z database is only reliably navigatable via Z,

    * I can clean this up, I was thinking along the lines of trying to determine how prevalent it is throughout the Z database, without looking for individual PDFs.
    * Thanks
  • thanks -- I actually meant the custom location for ZotFile, not the renaming rule, sorry.
    Or is your "collection" a reference to the Z database, if the latter I do not know, HoudaSpot only finds it in the Zotfile folder, but my experience is the Z database is only reliably navigatable via Z,
    right, I mean in Zotero and no, your file search engine wouldn't find that. You'd probably know, though, or how complicated is your Zotero library?

    So we still have PDFs being left behind after they should be moved by ZotFile, that'd seem to be the main issue.
    First thing to check would be if Zotero is still aware of that PDF. Paste 3NCCQ756 into the quick search bar in "All Fields and Tags" Mode with "My Library" selected on the left. Any results?
  • My Z library - no idea on the complicated, suspect so,
    * Online storage is 1.24 GB and
    * The /Users/moses/Library/Application Support/Firefox/Profiles/qlcdz25g.default/zotero/ folder is 3.78 GB,
    * The /Users/moses/Dropbox/Zotfile_Zotero/ folder is 1.4 GB

    - How do you interpret this distribution, if that is a reasonable question, I had some vague thought that I should be able to reconcile the numbers,

    Zotero is still aware of the SomeFile PDF. Pasting 3NCCQ756 into the quick search bar - is a nice thing to know of - returned SomeFile in the results,
  • Those numbers seem reasonable. There are additional files in /zotero and the data are compressed online, so you'd expect that folder to be bigger.

    The last bit is interesting -- so what icon does Zotero show for that file? Files stored in Zotero have a PDF-type icon (with the adobe logo and a bit of red). Files moved by ZotFile should just show a white rectangle with a link icon on top of it. Which do you see?
  • I see the PDF-type icon for /Users/moses/Library/Application Support/Firefox/Profiles/qlcdz25g.default/zotero/storage/3NCCQ756/SomeFile.pdf

    I see the Zotfile link for

    /Users/moses/Dropbox/Zotfile_Zotero/Sociology\ Compass/SomeFile.pdf


    and

    /Users/moses/Dropbox/Zotfile_Zotero/Sociology\ Compass/SomeFile_3.html (This is in duplicate)

    and for

    /Users/moses/Dropbox/Zotfile_Zotero/BloodPressure/SomeFile.pdf


    ... This also looks like the use of rename twice creating two Versions differently stored and leaving the PDF in the Z library.

    Clearly awry, solving the glitch and the cleanup is the issue,

    Best,
  • But that sounds like the item actually exists twice in Zotero, not just on your harddisk. Is that right?
  • edited April 13, 2016
    No,

    Once in the Z database,

    Twice in the ZotFile folder hosted in DropBox,
  • Here is a good example of the duplication and remainder pdfs in the Z database I sometimes encounter,

    https://www.evernote.com/l/AAdvpKJNAQNM7IW6ejbyCNzuiZYMNXvOIuE

    Best,
  • Very odd. And deleting these attachments in Zotero individually works, right? (i.e. click on one of the duplicate PDFs --> move item to trash).

    And can you reliably _cause_ these duplicates to appear? I.e. they appear immediately after using ZotFile's rename or so?

    (Also, just to make sure that we're talking the same language here: I would describe this as the same attachment existing three times in Zotero under a single item).
  • and one thought -- you don't happen to rely on the merge duplicate function a lot, do you? I could see that as at least potentially related.
  • Thank you for replying,

    Yes on "And deleting these attachments in Zotero individually works, right?"

    Agree 'I would describe this as the same attachment existing three times in Zotero under a single item."

    I see the duplicates like in the image I sent now and then, once a month max, I cannot reproduce,

    ... But you are right I do check for duplicates and merge them - next time I do that I will pay attention to the outcome, rather than trust,

    Best,

    K
  • yeah, I think this is entirely the effect of merging duplicates and the way it works: currently, when you merge two duplicate items, they contain all attachments from all items. The rationale for that is pretty straightforward -- Zotero can't know which is the right attachment, if you have annotations on one that you want to keep etc.
    Obviously keeping identical attachments isn't ideal and that should (and will eventually) change, but that's how merging duplicates currently works and I'd expect that to be the explanation for what you're seeing. It has nothing to do with sync, ZotFile etc.
  • Thanks!!! for letting me know about that particular quirk of Merge Duplicates. Still quirky that Rename Attachments does not rename all the attachments and leaves a remainder in the Z database. I can live with the quirky bits - just have to know they are there, Best,
  • edited July 11, 2016
    Dear All

    I migrated from Mendeley to Zotero and this specific issue created multiple copies of the same attachments in each item. Now my library is overpopulated of several copies of the same PDF.

    I am not sure this behaviour should be normal. At least there should be the possibility to govern the general behaviour when multiple copies of the same PDF are encountered. There are actually a number a ways to check if two PDFs are really the same. My specific problem is not that I do not see a specific way to purge my database. Could anyone help me?

    Best
  • I can't think of an easy way of purging multiple PDF attachments from items automatically (which I understand to be your questions)
  • I am posting here because it is a purging PDFs issue again,

    ID 603852536

    Description: Deleting an item in the Zotero Standalone App (Mac, Mojave 10.14.1, Zotero 5.0.65,) leaves a remainder, the attachments in, e.g., /Users/AAA/Dropbox/Zotfile_Zotero/xxx/yyy/zzz.pdf, no amount of syncing removes this, e.g., .pdf. Note. The Trash has been emptied. Any guidance would be good, I kind of expected that .pdf to be trashed, I have had that expectation quite a few times without going back and checking. Looking for others reporting the survival of this type of remainder, Thanks,
  • edited April 6, 2019
    @KevinMoses: Zotero doesn't remove linked files when you delete the items, since it doesn't know if you're using them outside Zotero. If you want Zotero to fully manage your files, you need to use stored files instead.
  • Thanks for the information, Best, KM
Sign In or Register to comment.