perrette/papers

"list index out of range" issue stops multi-file adds

cbedwards opened this issue · 2 comments

Absolutely loving this project. I have several folders of many pdfs I'm trying to add to papers, using

papers add -rc *.pdf

papers is hitting an error, with output

Traceback (most recent call last):
File "/usr/local/bin/papers", line 5, in
papers.bib.main()
File "/usr/local/lib/python3.4/dist-packages/papers/bib.py", line 1343, in main
check_install() and addcmd(o)
File "/usr/local/lib/python3.4/dist-packages/papers/bib.py", line 969, in addcmd
**kw)
File "/usr/local/lib/python3.4/dist-packages/papers/bib.py", line 390, in add_pdf
entry = bib.entries[0]
IndexError: list index out of range

And when it does this, none of the references have been added to the .bib file.

This happens if I include --ignore-errors as an argument, or don't use the -rc options. I've used setup to set up a config, and entering papers by hand works, as has several folders of just a few papers.

Suggestions?

Thanks!

Sorry, I have not been behind the project very much.
In case you'd want to come back to it, I can have a look into the error.
If you have minimal working example, or send me your pdf folders, I can go through it and find out what goes wrong.

I noted a few cases where DOI fetching would return "Ressource not found" and so the bibtextparser would fail. I resolved that particular case, but that was not related to the -rc options.