Skip to content

Try to fix FileNotFoundException on selecting default JStyles #13075

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

Merged
merged 1 commit into from
May 7, 2025

Conversation

subhramit
Copy link
Member

Closes #13073
This is an internal PR to observe any side-effects.
The issue occurs only when running via gradle, and not on installing via dmg/msi.
Description of fix based on artifact.

Mandatory checks

  • I own the copyright of the code submitted and I license it under the MIT license
  • [/] Change in CHANGELOG.md described in a way that is understandable for the average user (if change is visible to the user)
  • [/] Tests created for changes (if applicable)
  • Manually tested changed features in running JabRef (always required)
  • [/] Screenshots added in PR description (if change is visible to the user)
  • 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.

Signed-off-by: subhramit <subhramit.bb@live.in>
Copy link

trag-bot bot commented May 7, 2025

@trag-bot didn't find any issues in the code! ✅✨

@subhramit subhramit requested review from Siedlerchr and koppor May 7, 2025 13:31
@subhramit subhramit changed the title Try to fix FileNotFoundException on selecting default JStyle Try to fix FileNotFoundException on selecting default JStyle May 7, 2025
@subhramit subhramit added the status: ready-for-review Pull Requests that are ready to be reviewed by the maintainers label May 7, 2025
@subhramit subhramit changed the title Try to fix FileNotFoundException on selecting default JStyle Try to fix FileNotFoundException on selecting default JStyles May 7, 2025
Copy link
Contributor

github-actions bot commented May 7, 2025

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

@Siedlerchr Siedlerchr added this pull request to the merge queue May 7, 2025
Merged via the queue into main with commit d8cd25b May 7, 2025
2 checks passed
@Siedlerchr Siedlerchr deleted the jstyle-path branch May 7, 2025 18:46
Comment on lines +280 to +282
URL resUrl = JStyle.class.getResource(path);
if (resUrl != null) {
try (InputStream stream = resUrl.openStream()) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was thinking of ...getResourceAsStream, but I had no time to experiment. Maybe at a follow-up?

We need getResourceAsStream for GraalVM - see JabRef#693

@subhramit subhramit added dev: hotfix High-level fix for a bug, may need root-cause investigation in future. and removed status: ready-for-review Pull Requests that are ready to be reviewed by the maintainers labels May 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dev: hotfix High-level fix for a bug, may need root-cause investigation in future.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

File Not Found Exception when selecting default JStyles
3 participants