retorquere / zotero-better-bibtex

Make Zotero effective for us LaTeX holdouts
https://retorque.re/zotero-better-bibtex/
MIT License
5.28k stars 284 forks source link

preprint link to published article #1611

Closed ADB991 closed 4 years ago

ADB991 commented 4 years ago

Not everyone has access to journal articles, but everyone has access to arXiv. I like to include, when available, a link to the arXiv when citing a published journal article. The way I do it is by adding these fields in the bibtex entry:

eprint={quant-ph/9609002},
archivePrefix={arXiv},
primaryClass={quant-ph}

What should I do, within zotero and BBT, so that when I export the bibtex entry I get these fields too?

The process need not be fully automatic, I don't mind entering some data by hand in Zotero.

label-gun[bot] commented 4 years ago

It looks like you did not upload an debug report. The debug report is important; it gives @retorquere your current BBT settings and a copy of the problematic reference as a test case so he can best replicate your problem. Without it, @retorquere is effectively blind. Debug reports are useful for both bug analysis and enhancement requests; in the case of export enhancements, I need the copy of the references you have in mind.

This request is much more likely than not to apply to you, too, even if you think it unlikely, and even if it does not, there's no harm in sending a debug log that turns out to be unnecessary. @retorquere will more often than not just end up saying "please send a debug log first". Let's just skip over the unnecesary delay this entails. Sending a debug log is very easy:

  1. If your issue relates to how BBT behaves around a specific reference(s), such as citekey generation or export, select at least one of the problematic reference(s), right-click it, and submit an BBT debug report from that popup menu. If the problem is with export, please do include a sample of what you see exported, and what you expected to see exported for these references.

  2. If the issue does not relate to references and is of a more general nature, generate an debug report by restarting Zotero with debugging enabled (Help -> Debug Output Logging -> Restart with logging enabled), reproducing your problem, and selecting "Send Better BibTeX debug report..." from the help menu.

Once done, you will see a debug ID in red. Please post that debug id in the issue here.

Thank you!

ADB991 commented 4 years ago

GH8S9LZL-euc

ADB991 commented 4 years ago

it's not a bug, it's a usage question / feature request, but I don't know how to remove bug label

retorquere commented 4 years ago

You can either add a line to your extra field:

arXiv: quant-ph/9609002

or have a Journal article with a journal field like:

arXiv:quant-ph/9609002
retorquere commented 4 years ago
  1. If your issue relates to how BBT behaves around a specific reference(s), such as citekey generation or export, select at least one of the problematic reference(s), right-click it, and submit an BBT debug report from that popup menu. If the problem is with export, please do include a sample of what you see exported, and what you expected to see exported for these references.
  2. If the issue does not relate to references and is of a more general nature, generate an debug report by restarting Zotero with debugging enabled (Help -> Debug Output Logging -> Restart with logging enabled), reproducing your problem, and selecting "Send Better BibTeX debug report..." from the help menu.

GH8S9LZL-euc was sent using method 2 ("does not relate to references"), I need a log generated by method 1.

blip-bloop commented 4 years ago

:robot: this is your friendly neighborhood build bot announcing test build 5.2.54.6967 ("category for pre-2007 arXiv")

Install in Zotero by downloading test build 5.2.54.6967, opening the Zotero "Tools" menu, selecting "Add-ons", open the gear menu in the top right, and select "Install Add-on From File...".

retorquere commented 4 years ago

6967 adds the primaryClass for pre-2007 arXiv keys.

ADB991 commented 4 years ago

Neither solution works... The first one, just adds a note field in the bibtex entry, like this

    @article{rovelli1996,
    title = {Relational {Quantum} {Mechanics}},
    volume = {35},
    doi = {10.1007/BF02302261},
    number = {8},
    urldate = {2020-08-07},
    journal = {International Journal of Theoretical Physics},
    author = {Rovelli, Carlo},
    month = aug,
    year = {1996},
    note = {arXiv: quant-ph/9609002},
}

The second one clearly does not work as I am talking specifically for when the article is already published.

ADB991 commented 4 years ago

For reference, what I want is:

    @article{rovelli1996,
    title = {Relational {Quantum} {Mechanics}},
    volume = {35},
    doi = {10.1007/BF02302261},
    number = {8},
    urldate = {2020-08-07},
    journal = {International Journal of Theoretical Physics},
    author = {Rovelli, Carlo},
    month = aug,
    year = {1996},
        eprint={quant-ph/9609002},
        archivePrefix={arXiv},
        primaryClass={quant-ph}
}
ADB991 commented 4 years ago

this is the debug report 5PJNJHDM-euc

retorquere commented 4 years ago

Do bibtex styles support these fields? I thought that was a biblatex thing.

If the article is already published, and you want to include the journal name, why include the arXiv information? That would make the reference ambiguous - if the reader wants to pick up the article, should they get it from arXiv or from the publisher?

ADB991 commented 4 years ago

Yes it works for me. It's bibtex.

The reason to include both the DOI and the arXiv identifier is to help out the reader. Not everyone has access to journals online, or maybe they do, but they need to connect to a VPN. Also, I like reading the arXiv versions, I'm more used to that typesetting style.

retorquere commented 4 years ago

I can add them for bibtex, and you can get the ambiguous reference using the extra field, but I'd recommend against actually citing anything this way that will actually be submitted to a publisher (or graded if you're still in uni). Ambiguous references will be counted against you. The DOI is different as a published article could have a DOI, so that would not be ambiguous.

retorquere commented 4 years ago

Wait -- bibtex export already has it. Given 5PJNJHDM-euc I'm getting the fields as you want. But you have not installed 6967

ADB991 commented 4 years ago

It's not working for me. I have also tried after installing 6967. Debug: 2DDBNGTL-euc I also have trouble as it keeps adding a lot of fields I told it not to add in the Preferences panel (like abstract, file, annote etc)

qqobb commented 4 years ago

@ADB991: Are you actually using BBT's export translator? Maybe you're using Zotero's own translator. See [1].

[1] Zotero and LaTeX/BibTeX, PDF by Christine Malinowski for MIT Libraries (2018).

retorquere commented 4 years ago

Good point - can you post the actual output you get?

ADB991 commented 4 years ago

damn! that worked! I'm sorry i wasted your time.... It works exactly as expected!

So, I've been using Zotero export all this time.. Thank god you made BBT!

github-actions[bot] commented 3 years ago

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.