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

Missing jabrefHost.py on 5.10/5.11 causing the browser extension to fail #10308

Closed
2 tasks done
allydunham opened this issue Sep 4, 2023 · 15 comments · Fixed by #10340
Closed
2 tasks done

Missing jabrefHost.py on 5.10/5.11 causing the browser extension to fail #10308

allydunham opened this issue Sep 4, 2023 · 15 comments · Fixed by #10340
Labels
bug Confirmed bugs or reports that are very likely to be bugs build-system os: macOS

Comments

@allydunham
Copy link
Contributor

JabRef version

5.10 (latest release)

Operating system

macOS

Details on version and operating system

No response

Checked with the latest development build (copy version output from About dialog)

  • I made a backup of my libraries before testing the latest development version.
  • I have tested the latest development version and the problem persists

Steps to reproduce the behaviour

  1. Install JabRef 5.10/5.11 on MacOS, either arm64 or intel.
  2. jabrefHost.py is missing from JabRef.app/Contents/Resources/
  3. Attempting to use the browser extension fails with error File at path "/Users/ad44/Applications/JabRef.app/Contents/Resources/jabrefHost.py" does not exist, or is not executable

Appendix

...

Log File
Paste an excerpt of your log file here
@Siedlerchr Siedlerchr added the bug Confirmed bugs or reports that are very likely to be bugs label Sep 4, 2023
@github-project-automation github-project-automation bot moved this to Normal priority in Prioritization Sep 4, 2023
@Siedlerchr
Copy link
Member

Thanks for the report. We totally missed this.

The file jabref host.py and https://github.com/JabRef/jabref/tree/main/buildres/mac/native-messaging-host
the files need to copied over.
https://github.com/JabRef/jabref/blob/main/buildres/mac/jabrefHost.py

Unfortunately there is no easy fix now as this could break notarization.
Refs adoptium/adoptium-support#829
File an issue with the project to the jdk.

@Siedlerchr
Copy link
Member

Need to test this:


`--app-content additional-content[,additional-content...]

    A comma separated list of paths to files and/or directories to add to the application payload.

    This option can be used more than once.

https://docs.oracle.com/en/java/javase/20/docs/specs/man/jpackage.html

@Siedlerchr
Copy link
Member

@allydunham I found a solution for the problem. Can you please test if this version works correctly?
https://builds.jabref.org/addAddContentToImage/ (It's arm64 only)
You might need to use the pgk as it overwrites the old path files for the browser extension.

github-merge-queue bot pushed a commit that referenced this issue Sep 10, 2023
* Copy browser extension files for mac

Fixes #10308

* fix path for jabref detection

* add changelog entry

* specify pgk
@github-project-automation github-project-automation bot moved this from Normal priority to Done in Prioritization Sep 10, 2023
@allydunham
Copy link
Contributor Author

I had to use the DMG because of admin permissions, but when I updated the plugin JSON manually this build works. Thanks for sorting it out.

@anteromontonio
Copy link

Thanks for the report. We totally missed this.

The file jabref host.py and https://github.com/JabRef/jabref/tree/main/buildres/mac/native-messaging-host the files need to copied over. https://github.com/JabRef/jabref/blob/main/buildres/mac/jabrefHost.py

Unfortunately there is no easy fix now as this could break notarization. Refs adoptium/adoptium-support#829 File an issue with the project to the jdk.

Could you please provide instruction where to copy the linked files. So far I put

bifehkofibaamoeaopjglfkddgkijdlh.json
in
/Library/Application\ Support/Google/Chrome/External\ Extensions/

and

org.jabref.jabref.json in
/Library/Google/Chrome/NativeMessagingHosts/

And the extension is not working

@Siedlerchr
Copy link
Member

Please use the latest development version (the pkg) (not yet notarized, so you have to use xattr -d com.apple.quarantine /Applications/JabRef.app afterwards
We are planning a release shortly.

@Siedlerchr
Copy link
Member

Siedlerchr commented Oct 17, 2023

@anteromontonio Here is also now a completely notarized version https://builds.jabref.org/buildnotarizedversion/
I recommend installing the pkg version as it takes care of the extension

@koppor
Copy link
Member

koppor commented Oct 24, 2023

For reference: https://builds.jabref.org/buildnotarizedversion/ is not available any more, but release v5.11 contains the fix.

@MooersLab
Copy link

MooersLab commented Oct 30, 2023

I tried both the pkg and dmg versions of 5.11 and both of them are still missing jabrefHost.py in /Applications/JabRef.app/Contents/Resources/. However, it is hiding out in /Applications/JabRef.app/Contents/.

@Siedlerchr
Copy link
Member

@MooersLab Yes, the path has changed. The browser plugin config is updated as well by the installer.

@MooersLab
Copy link

@Siedlerchr Thank you for the clarification. The Plugin is now working for me! :) This documentation needs updating: https://docs.jabref.org/collect/jabref-browser-extension#installation-and-configuration

@Siedlerchr
Copy link
Member

Siedlerchr commented Oct 30, 2023 via email

@felixschaumann
Copy link

I ran into a similar issue: On MacOS 14.0, the Firefox browser extensions wouldn't connect to my JabRef-5.11.dmg anymore. Without understanding all too much of what's going on, I will explain how I got it runnig again, in case other people have similar troubles.

It seems like my browser extension (reinstalled as the newest version) expects the jabrefHost.py in /Applications/JabRef.app/Contents/Resources, not in /Applications/JabRef.app/Contents, where it had been placed. So step 1 was to copy the jabrefHost.py over into the Resources folder. Still, JABREF_PATH was somehow wrong. I fixed that in step 2, by changing JABREF_PATH = script_dir / "bin/JabRef" to JABREF_PATH = script_dir / "MacOS/JabRef" within jabrefHost.py. Now it works again :)

@Siedlerchr
Copy link
Member

Have you tried the pkg installer? That should take care of the browser extension files

@felixschaumann
Copy link

Have you tried the pkg installer? That should take care of the browser extension files

Yes, I had tried that, but it didn't help in my case. At least not by itself — I think I had fixed the issues for the .pkg version in the same way as I detailed for the .dmg version, but then JabRef always crashed after importing a reference, so I went back to .dmg. Either way, that is working fine now :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Confirmed bugs or reports that are very likely to be bugs build-system os: macOS
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

6 participants