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

Fix exception when opening preferences #10294

Merged
merged 3 commits into from
Sep 3, 2023
Merged

Conversation

koppor
Copy link
Member

@koppor koppor commented Sep 3, 2023

I "forgot" to properly handly self-containedness at the exporters. This caused

Caused by: java.lang.IllegalArgumentException: TABLE requires external lookup.
	at [email protected]/org.jabref.model.metadata.selfcontainedsaveorder.<init>(selfcontainedsaveorder.java:12)
	at [email protected]/org.jabref.model.metadata.selfcontainedsaveorder.of(selfcontainedsaveorder.java:25)
	at [email protected]/org.jabref.preferences.jabrefpreferences.getexportconfiguration(jabrefpreferences.java:2275)
	at [email protected]/org.jabref.preferences.jabrefpreferences.getcustomexportformats(jabrefpreferences.java:2281)

The underlying issue is that concrete exporters are generated in the preferences. In future work, this should be solved. This PR "only" fixes that setting the preferences works again.

There is SelfContainedSaveConfiguration introduced analogous to SelfContainedSaveOrder.

Mandatory checks

  • Change in CHANGELOG.md described in a way that is understandable for the average user (if applicable)
  • Tests created for changes (if applicable)
  • Manually tested changed features in running JabRef (always required)
  • Screenshots added in PR description (for UI changes)
  • Checked developer's documentation: Is the information available and up to date? If not, I outlined it in this pull request.
  • Checked documentation: Is the information available and up to date? If not, I created an issue at https://github.com/JabRef/user-documentation/issues or, even better, I submitted a pull request to the documentation repository.

@github-actions
Copy link
Contributor

github-actions bot commented Sep 3, 2023

Your code currently does not meet JabRef's code guidelines. The tool reviewdog already placed comments on GitHub to indicate the places. See the tab "Files" in you PR. Please carefully follow the setup guide for the codestyle. Afterwards, please run checkstyle locally and fix the issues.

More information on code quality in JabRef is available at https://devdocs.jabref.org/getting-into-the-code/development-strategy.html.

Siedlerchr
Siedlerchr previously approved these changes Sep 3, 2023
@Siedlerchr Siedlerchr enabled auto-merge September 3, 2023 11:18
@Siedlerchr Siedlerchr added this pull request to the merge queue Sep 3, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Sep 3, 2023

The build for this PR is no longer available. Please visit https://builds.jabref.org/main/ for the latest build.

Merged via the queue into main with commit 1e0bbea Sep 3, 2023
@Siedlerchr Siedlerchr deleted the fix-exception-at-preferences branch September 3, 2023 12:03
Siedlerchr added a commit that referenced this pull request Sep 3, 2023
* upstream/main:
  Use OpenRewrite UseStringReplace (#10299)
  Add ReplaceStringBuilderWithString (#10302)
  Apply ShortenFullyQualifiedTypeReferences (#10301)
  Apply StaticMethodNotFinal (#10300)
  Apply exit early pattern (#10297)
  Avoid GH_TOKEN_UPDATE_GRADLE_WRAPPER at refresh-csl-subtrees
  Update snapcraft.yaml
  Fix exception when opening preferences (#10294)
  gnome-42-2204
  use gnome 4.2
  Use gnome
  Update base 22
Siedlerchr added a commit that referenced this pull request Sep 3, 2023
* upstream/main: (737 commits)
  Use OpenRewrite UseStringReplace (#10299)
  Add ReplaceStringBuilderWithString (#10302)
  Apply ShortenFullyQualifiedTypeReferences (#10301)
  Apply StaticMethodNotFinal (#10300)
  Apply exit early pattern (#10297)
  Avoid GH_TOKEN_UPDATE_GRADLE_WRAPPER at refresh-csl-subtrees
  Update snapcraft.yaml
  Fix exception when opening preferences (#10294)
  gnome-42-2204
  use gnome 4.2
  Use gnome
  Update base 22
  Add method for detecting journal abbrev delimiter (#10281)
  Update bug_report.yml
  Fix selection of table sort order (#10250)
  Fix mixup with YAML tags (#10287)
  More guards for upload (#10282)
  Reduced calls to Globals.prefs and Globals.entryTypesManager (#10177)
  Update jmh plugin (#10279)
  Add computer science to protected terms (#10222)
  ...

# Conflicts:
#	build.gradle
#	src/main/java/module-info.java
#	src/main/java/org/jabref/cli/Launcher.java
#	src/main/java/org/jabref/preferences/JabRefPreferences.java
#	src/main/resources/tinylog.properties
Siedlerchr added a commit that referenced this pull request Sep 4, 2023
…ustStore

* upstream/main: (295 commits)
  Use OpenRewrite UseStringReplace (#10299)
  Add ReplaceStringBuilderWithString (#10302)
  Apply ShortenFullyQualifiedTypeReferences (#10301)
  Apply StaticMethodNotFinal (#10300)
  Apply exit early pattern (#10297)
  Avoid GH_TOKEN_UPDATE_GRADLE_WRAPPER at refresh-csl-subtrees
  Update snapcraft.yaml
  Fix exception when opening preferences (#10294)
  gnome-42-2204
  use gnome 4.2
  Use gnome
  Update base 22
  Add method for detecting journal abbrev delimiter (#10281)
  Update bug_report.yml
  Fix selection of table sort order (#10250)
  Fix mixup with YAML tags (#10287)
  More guards for upload (#10282)
  Reduced calls to Globals.prefs and Globals.entryTypesManager (#10177)
  Update jmh plugin (#10279)
  Add computer science to protected terms (#10222)
  ...
@Siedlerchr Siedlerchr mentioned this pull request Sep 14, 2023
2 tasks
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

Successfully merging this pull request may close these issues.

2 participants