Adding notifications when writing metadata to pdfs#8647
Merged
Conversation
Adding notifications when writing metadata to pdfs
Member
|
Wow, this already looks pretty good. Definitely a step forward! Thank you! |
Member
|
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 |
Siedlerchr
reviewed
Apr 6, 2022
| } 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); |
Member
There was a problem hiding this comment.
Please also log the message using LOGGER.error(...)
Siedlerchr
reviewed
Apr 6, 2022
| } 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); |
Member
There was a problem hiding this comment.
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.")
Member
Member
|
Thanks for the follow up! Please have a look at the failing test |
Member
|
I took the opportunity to fix and slighly reword the localization. |
koppor
approved these changes
Apr 10, 2022
Member
|
Thanks nontheless for your contribution @AntonioIgorCarvalho |
Siedlerchr
added a commit
that referenced
this pull request
Apr 11, 2022
…-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)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Adding notifications when writing metadata to pdfs
Fixes #8276
Simple notifications added when clicking in this button specifically, as mentioned in issue #8276

CHANGELOG.mddescribed 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:
