-
-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Support BibLaTeX datamodel validations #13693
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
Support BibLaTeX datamodel validations #13693
Conversation
jablib/src/test/java/org/jabref/logic/biblog/BibtexLogParserTest.java
Outdated
Show resolved
Hide resolved
jablib/src/test/java/org/jabref/logic/biblog/BibtexLogParserTest.java
Outdated
Show resolved
Hide resolved
if (message.startsWith(EMPTY_FIELD_PREFIX)) { | ||
fieldName = message.substring(EMPTY_FIELD_PREFIX.length()).trim(); | ||
fieldName = FieldFactory.parseField(fieldName).getName(); | ||
// For BiblaTex warnings |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Comment adds no value as it merely restates what is obvious from the code. Should be removed or enhanced with additional context.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do not camel case latex or bibtex or biblatex in variable names.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Scrolled through. On the road, therefore only quick comment
Would be nice if you changed JavaDoc comments to markdown style. That is more maintainable. (/// And markdown instead of /*)
…tex and bibtex in variable names instead of camel case.
Note that your PR will not be reviewed/accepted until you have gone through the mandatory checks in the description and marked each of them them exactly in the format of |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks good - let's see, how it behaves in practise.
I go ahead with merging.
/// **Parameters:** | ||
/// * `line` - The single line from the .blg file to parse. | ||
/// | ||
/// **Returns:** | ||
/// * An `Optional` containing a `BibWarning` if a match is found, or an empty `Optional` otherwise. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please use JavaDoc format - see deleted code for the format to be used.
I fixed in 7ee3497.
@trag-bot didn't find any issues in the code! ✅✨ |
…n-c23b1a88-5c29-46a2-a007-701edd344b9b' into jetbrains-junie-issue-13623-run-c23b1a88-5c29-46a2-a007-701edd344b9b * upstream/jetbrains-junie-issue-13623-run-c23b1a88-5c29-46a2-a007-701edd344b9b: Streamline code for getTabTitle() (#13781) Add missing variables Reformat BibTex in Show BibTex Source (#13761) Auto publish before JBang tests (#13779) Hotfix: calling of publish.yml Support BibLaTeX datamodel validations (#13693) Auto add and remove of "status: changes-required" label (#13778) New Crowdin updates (#13777) Restore local-only Git behavior for SLR to fix repository initialization error (#13775) Use vanilla hashset (#13771) Fix Springer Fetcher names (#13770) Fix condition Publish SNAPSHOT on jablib change (#13774) Adapt as per new set of checks (#13772) Bump jablib/src/main/resources/csl-styles from `1194364` to `17cfa60` (#13750) Fix path (#13769) Mode aware consistency check (#13584) Refine JBang check (#13765) Add Language Server to the UI and add the integrity/consistency check (#13697) Fix/remove comment code (#13763)
Closes #13318
I've updated the
BibtexLogParser
class by adding a newBIBLATEXT_WARNING_PATTERN
to specifically recognize and parse Biber's data model validation warnings. Concurrently, a new@ParameterizedTest
was implemented inBibtexLogParserTest
to thoroughly test this new pattern, ensuring the parser correctly extracts information from these distinct warning messages. This enables JabRef to now support a wider range of Biber's log outputs.Steps to test
You can test the business by just running
parsesBiblaTexValidationWarnings
test inBibtexLogParserTest
.In other way, you can also see validation messages in
Check Integrity
in JabRef.The warnings in the screenshot has been catched by the new pattern.
Mandatory checks
CHANGELOG.md
described in a way that is understandable for the average user (if change is visible to the user)