Content negotiation bibtex url field

A user of habanero opened an issue recently

curl -L -H "Accept: application/x-bibtex" "https://0-doi-org.libus.csd.mu.edu/10.1021/acs.jpcc.0c05161"

gives

@article{Shao_2020,
	doi = {10.1021/acs.jpcc.0c05161},
	url = {https://0-doi-org.libus.csd.mu.edu/10.1021%2Facs.jpcc.0c05161},
	year = 2020,
	month = {oct},
	publisher = {American Chemical Society ({ACS})},
	volume = {124},
	number = {43},
	pages = {23479--23489},
	author = {Jingjing Shao and Vincent Pohl and Lukas Eugen Marsoner Steinkasserer and Beate Paulus and Jean Christophe Tremblay},
	title = {Electronic Current Mapping of Transport through Defective Zigzag Graphene Nanoribbons},
	journal = {The Journal of Physical Chemistry C}

The url field in the result has the slash after the DOI prefix URL encoded as %2F instead of /. I’ve checked a handful of other DOIs with the same result. The URL seems to be fine in other formats.

One can easily fix on the client side, e.g., in Python

from habanero import cn
bibtex_string = cn.content_negotiation(ids='10.1021/acs.jpcc.0c05161')
from urllib.parse import unquote
unquote(bibtex_string)

But, it’s ideal if it can be fixed wherever the code is for serializing to bibtex format

code error at run time

Thanks for letting us know. I’ve reported this issue to our tech team as well.

2 Likes

Thanks very much for the response