Bug: Google doc issue with deleted citatitions

When you delete a citation in the document, visible text
goes away, reference is the deleted from the bibliogrpahy list, but a copy of that reference including name and DOI stays hidden in the document and never goes away.

I've run into this issue by adding a paper that had a comment on pubpeer and triggered my other extension - PubPeer that shows papers that has comment on pubpeer in browser.

When I deleted the citatition and pressed refresh, the banner "This article has comments on pubpeer" never went away even though it was not present in the document or bibliography anymore

It seems like the deleted citation is still present inside source code without being visible in references/text.

I've managed to fix this behaviour using LLM, and it seems that the problem lies in the fact that documents.get() API call never returns those deleted citations because they are not present in the text. LLM created a workaround around API so I guess it's not a good solution and should probably be fixed upstream rather than in this extenstion. Not sure what your stance on code created by LLM is but if you want I can create a PR/post proposed changes for you to review them (+60 lines)

  • I'm not entirely what the problem is. For one, when you remove a citation from the document, its visible text, and it disappears from the bibliography, then it's totally gone from the document. It seems that your LLM confirmed that the Google Docs documents API also doesn't return the citation. So it seems like it's a bug in your PubPeer extension. I don't know how it works, but it's likely that after removing the citation and refreshing the Google Docs browser tab it will disappear from PubPeer. If not, you should report it to them.
  • edited today at 4:14pm
    >After removing the citation and refreshing the Google Docs browser tab it will disappear
    That is exactly what is not happening. It stayed there after I reloaded cache, switched browser , entered incognito mode and switched to another OS.

    I've attached screenshots. On the first one the reference is present and triggers the correct response. On the second one it is absent (and bibliography is deleted) but it still trigers the response which shoudn't happen. On the third one I highlighted source code that lies within Google Doc Zotero Integration extenstion and it still hold the citation metadata (including pubmed id that triggers other extenstion response) about the deleted citation which is not correct behaviour?

    https://s3.amazonaws.com/zotero.org/images/forums/u11470510/cepp3qmqeaq9t1cqvtfz.png

    https://s3.amazonaws.com/zotero.org/images/forums/u11470510/gilpgby2a1s6dpabn098.png

    https://s3.amazonaws.com/zotero.org/images/forums/u11470510/u7psv80ti5igk7huflxv.png
  • It's possible that Google Docs serializes old versions of the document (restorable via document history) in the html tags. If PubPeer extension uses that for something, that is a bug in their extension. If this citation data is not available via the Google Docs API, then there's nothing else we can do on our side to prevent it from being embedded on the page by Google Docs own document editor for whatever reason it decides to do that.
Sign In or Register to comment.