jgilchrist / pybib

Get BibTeX citations from your terminal
BSD 3-Clause "New" or "Revised" License
26 stars 2 forks source link

Invalid DOI error #2

Closed twsh closed 9 years ago

twsh commented 9 years ago

I tried to run pybib with your examples. It works fine from the command line. But when I put them in a file 'foo.doi' and do $ bib -f foo.doi I get error messages like: 'Line 1: Invalid DOI 10.1145/2043164.2018477'. This is, of course, a valid DOI. I'm using the latest version installed with Pip3 on Yosemite.

jgilchrist commented 9 years ago

Hi @twsh, sorry you're having problems!

Could you please post the contents of the file you're using?

twsh commented 9 years ago

I tried it with the example from your Reddit post:

network_failures        10.1145/2043164.2018477
comp_sci_ubiq           10.1145/159544.159617

Which is odd because presumably that works fine for you. And the DOI is says is invalid isn't, and works as $ bib 10.1145/2043164.2018477.

jgilchrist commented 9 years ago

I updated the regular expression which matches DOIs relatively recently - the new version is evidently a little broken.

I'm about to push a fix as v1.2.2, could you please try it out and let me know if it fixes your problem?

twsh commented 9 years ago

Great! The new version fixes the problem.

jgilchrist commented 9 years ago

Fantastic, thank you! If you've got any more problems/suggestions feel free to open another issue.