bibcure / doi2bib

get the bibtex string given a doi
https://doi2bib.readthedocs.io/
MIT License
186 stars 27 forks source link

Error in Cyrillic macros #9

Closed crazytexer closed 1 year ago

crazytexer commented 3 years ago

Thank you very much for this module! It is very, very helpful.

There is something which seems to be a bug. When I use get_bib_from_doi(...) (from doi2bib.crossref) for the doi corresponding to a paper in Russian, the Cyrillic letters are represented as \cyrchar\CYRA (for Cyrillic А), \cyrchar\CYRB (for Cyrillic Б), etc. That's fine. But very often I see an error like \cyrchar\{CYRA}. It is not a valid (La)TeX code; symbols \ and { between \cyrchar and CYRA} should be swapped.

For example,

from doi2bib.crossref import get_bib_from_doi
bib = get_bib_from_doi('10.7868/S0023420617030050')
print(bib[1])

gives

...journal = {{\cyrchar\{CYRK}}{\cyrchar\cyro}...

I also reported this bug in the similar project: https://github.com/davidagraf/doi2bib2/issues/23

crazytexer commented 1 year ago

OK, I see now that this bug is actually outside doi2bib so I'm closing the issue.