syncthing/syncthing-macos

When Syncthing.app is first time started from DMG under /Volumes the Executable is set and not reset back to /Applications

Opened this issue · 17 comments

Recap:

  • Downloaded the DMG release
  • Mounted DMG
  • Installed it on macOS 12.6 by putting .app in Application folder
  • Unmounted DMG
  • Tried to open - nothing happened just tray icon seen for "0.00001 s" and disapeared
  • Nothing works in background
  • The ~/Library/Application Support/Syncthing/syncthing.log syncthing daemon logfile is NOT created

Works only if dmg is mounted

Hi @bartek-galazka, thanks for the report. Could you check the following:

  • Which version are you using?
  • Execute defaults read com.github.xor-gate.syncthing-macosx Executable from Terminal.app (console)

My iMac is running still on macOS 12.7.6 so I have a similair setup.

Check for Quarantine Flag

macOS sometimes adds a quarantine flag when downloading apps from the internet, preventing the app from launching properly.

To check for the quarantine flag, run the following command in Terminal:
xattr -lr /Applications/<YourApp>.app

If you see com.apple.quarantine in the output, remove the quarantine flag using:
sudo xattr -dr com.apple.quarantine /Applications/<YourApp>.app

Gatekeeper and App Verification

Sometimes macOS Gatekeeper blocks apps from unknown developers.
Try opening the app by right-clicking the app in /Applications and selecting Open. This often forces Gatekeeper to bypass the security warning.
You can also check System Preferences → Security & Privacy → General to allow the app to be opened if a warning is listed

Hi @bartek-galazka, thanks for the report. Could you check the following:

  • Which version are you using?
  • Execute defaults read com.github.xor-gate.syncthing-macosx Executable from Terminal.app (console)

My iMac is running still on macOS 12.7.6 so I have a similair setup.

Syncthing-1.27.12-1.dmg

image

Check for Quarantine Flag

macOS sometimes adds a quarantine flag when downloading apps from the internet, preventing the app from launching properly.

To check for the quarantine flag, run the following command in Terminal: xattr -lr /Applications/<YourApp>.app

If you see com.apple.quarantine in the output, remove the quarantine flag using: sudo xattr -dr com.apple.quarantine /Applications/<YourApp>.app

I did this. Still doesn't work. But I still see many other things in the output like this:

image

Maybe this is the reason?

Gatekeeper and App Verification

Sometimes macOS Gatekeeper blocks apps from unknown developers. Try opening the app by right-clicking the app in /Applications and selecting Open. This often forces Gatekeeper to bypass the security warning. You can also check System Preferences → Security & Privacy → General to allow the app to be opened if a warning is listed

Not the case, that was the first thing I have checked :)

Now I noticed this:

image

What does Execute defaults read com.github.xor-gate.syncthing-macosx Executable from Terminal.app (console) say?

Please paste the whole error text and not a half a screenshot

  • defaults read com.github.xor-gate.syncthing-macosx Executable
image

Please paste the whole error text and not a half a screenshot

image

Problem is you have executed Syncthing.app first time from /Volumes (thus DMG). Reset by deleting the key. After delete quit Syncthing and restart the App.

jerry@Jerrys-iMac ~ % defaults read com.github.xor-gate.syncthing-macosx Executable
/Applications/Syncthing.app/Contents/Resources/syncthing/syncthing
jerry@Jerrys-iMac ~ % defaults delete com.github.xor-gate.syncthing-macosx Executable
jerry@Jerrys-iMac ~ % defaults read com.github.xor-gate.syncthing-macosx Executable
2024-10-03 18:14:06.948 defaults[23713:8389162]
The domain/default pair of (com.github.xor-gate.syncthing-macosx, Executable) does not exist
jerry@Jerrys-iMac ~ % defaults read com.github.xor-gate.syncthing-macosx Executable
/Applications/Syncthing.app/Contents/Resources/syncthing/syncthing

Maybe we should fix this and check if the Syncthing.app is executed from /Volumes. Reopening for an enhancement.

Just want to say I came here thinking nothing happened when my syncthing started (I started it from /Applications). Turns out the app doesn't have a UI like I thought, the UI is at http://localhost:8384/ and I just needed to go there

Just want to say I came here thinking nothing happened when my syncthing started (I started it from /Applications). Turns out the app doesn't have a UI like I thought, the UI is at http://localhost:8384/ and I just needed to go there

The Syncthing macOS bundle has a GUI and is only visible in the system status bar. When nothing shows up in the status bar you have hit issue #192. Also when you have a fresh installation we need #188.

Problem is you have executed Syncthing.app first time from /Volumes (thus DMG). Reset by deleting the key. After delete quit Syncthing and restart the App.

jerry@Jerrys-iMac ~ % defaults read com.github.xor-gate.syncthing-macosx Executable
/Applications/Syncthing.app/Contents/Resources/syncthing/syncthing
jerry@Jerrys-iMac ~ % defaults delete com.github.xor-gate.syncthing-macosx Executable
jerry@Jerrys-iMac ~ % defaults read com.github.xor-gate.syncthing-macosx Executable
2024-10-03 18:14:06.948 defaults[23713:8389162]
The domain/default pair of (com.github.xor-gate.syncthing-macosx, Executable) does not exist
jerry@Jerrys-iMac ~ % defaults read com.github.xor-gate.syncthing-macosx Executable
/Applications/Syncthing.app/Contents/Resources/syncthing/syncthing

I had the same issue, @xor-gate your solution helped. Thanks a lot.

How do I change the Executable?

How do I change the Executable?

As mentioned in the previous comments by me by typing the command in the Terminal.app then quit and start Syncthing from /Applications again:

defaults delete com.github.xor-gate.syncthing-macosx Executable

Thank You! I was confused with other terminal commands and over complicated it 😆. You are the best!