Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"comment" lines without leading @ breaks parser #43

Closed
auxym opened this issue Sep 25, 2014 · 1 comment
Closed

"comment" lines without leading @ breaks parser #43

auxym opened this issue Sep 25, 2014 · 1 comment

Comments

@auxym
Copy link

auxym commented Sep 25, 2014

I'm not sure if such lines conform to bibtex syntax, but they are found in standard packages. See, for example, IEEEabrv.bib.

Some minimal examples:

@STRING{Foo = "bar"}
This is a comment
This is a second comment.

This returns the incorrect dictionary entry OrderedDict([('foo', 'bar"} This is a comment This is a second comment.')])

@STRING{Foo = "bar"}
This is a comment
STRING{Baz = "This should be interpreted as comment."}

This raises an exception when parsed.

I had a quick look at the parser code. Maybe, instead of using a new @ line as the record delimiter, it should use the braces?

As a workaround, I'm removing all lines not starting with @ before parsing the aforementioned IEEEabrv.bib fil, but this only works because this particular file only has one-liners.

@sciunto
Copy link
Member

sciunto commented Apr 8, 2016

Fixed in master. Thanks.

@sciunto sciunto closed this as completed Apr 8, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants