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

Parsing breaks on JabRef comments #22

Open
stmichaelis opened this issue Dec 4, 2023 · 3 comments
Open

Parsing breaks on JabRef comments #22

stmichaelis opened this issue Dec 4, 2023 · 3 comments

Comments

@stmichaelis
Copy link

JabRef for managing BibTeX-libraries can add special settings in @Comment-Entries at the end of the file, e.g. @Comment{jabref-meta: databaseType:biblatex;}.
Parsing these breaks with an error unknown string variable: jabref-meta:. While these entries of course are not valid BibTeX, shouldn't comments be accepted "as is"?

@nickng
Copy link
Owner

nickng commented Dec 6, 2023

Yeah probably, the @comment spec I found was this.

If the entry type is @Comment, [it] is not considered to be the start of an entry. (Actually, the rule is that everything from the @Comment and to the end of line is ignored. The remainder lines of the commented entry is ignored by the first comment mechanism we described; in particular a @Comment does not need to be a valid entry, i.e. it can for example skip comas between two fields).

@stmichaelis
Copy link
Author

I would assume the definition in bibtex.y for commententry would need to changed, as longstring expects parsable BibTeX-entries? Unfortunately, I have no idea about yacc to be much of a help here.

@stmichaelis
Copy link
Author

My apologies for not getting back to you earlier. I assumed Github would notify me about updates here, seems not to be the case for commits mentioning an issue (or I overlooked it).

Tested the new release and can confirm it works for me.

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