-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Adding notifications when writing metadata to pdfs #8647
Conversation
Adding notifications when writing metadata to pdfs
Wow, this already looks pretty good. Definitely a step forward! Thank you! |
Please have a look at the faliing unit test regarding Localization, see also https://devdocs.jabref.org/getting-into-the-code/code-howtos#using-localization-correctly |
} catch (IOException | TransformerException ex) { | ||
// TODO: Print error message | ||
// Localization.lang("Error while writing") + " '" + file.toString() + "': " + ex; | ||
dialogService.notify(Localization.lang("Error while writing") + " '" + file.toString() + "': " + ex); |
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 also log the message using LOGGER.error(...)
} catch (IOException | TransformerException ex) { | ||
// TODO: Print error message | ||
// Localization.lang("Error while writing") + " '" + file.toString() + "': " + ex; | ||
dialogService.notify(Localization.lang("Error while writing") + " '" + file.toString() + "': " + ex); |
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.
Instead of printing the exception in the notify, I would add instead: dialogService.notify(Localization.lang("Error while writing metadata. See the error log for details.")
Thanks for the follow up! Please have a look at the failing test |
I took the opportunity to fix and slighly reword the localization. |
Thanks nontheless for your contribution @AntonioIgorCarvalho |
…-0.3.0' of github.com:JabRef/jabref into dependabot/gradle/com.github.tomtung-latex2unicode_2.12-0.3.0 * 'dependabot/gradle/com.github.tomtung-latex2unicode_2.12-0.3.0' of github.com:JabRef/jabref: try version 0.3.1 Save xmp data to new file and then copy it back (#8656) Adding notifications when writing metadata to pdfs (#8647)
Adding notifications when writing metadata to pdfs
Fixes #8276
Simple notifications added when clicking in this button specifically, as mentioned in issue #8276

CHANGELOG.md
described in a way that is understandable for the average user (if applicable)Screenshot with success:

Screenshot when writting in a deleted file:

Screenshot when writting in a corrupted file:

Error log when writting in a corrupted file:
