Repository navigation
fix(macos-app): remember Allow LAN access, and let it be set without the menu bar - #192
Merged
Merged
Conversation
…out the menu bar The DMG app forgot LAN access on every launch, and the menu-bar item was the only way to turn it on, so a Mac where macOS doesn't draw the icon had no way to reach the daemon from another device. - Persist the choice in user defaults (com.deckd.daemon AllowLAN) and show the checkmark from launch; `defaults write com.deckd.daemon AllowLAN -bool true` + relaunch enables it headless. - Reopening the running app (Finder, Spotlight, `open -a deckd`) opens the surface. - test-app.sh: start from a cleared choice, check it is saved and survives a relaunch. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
On my Mac the deckd.app menu-bar icon never showed up, which left no way to turn on Allow LAN access, so
http://<host>:8765wasn't reachable from other devices. Even when the menu works, the app forgets the choice on every launch, so you'd have to turn it on again after each reboot.Now the choice is remembered across launches and upgrades, and you can set it without the menu bar:
Opening deckd.app while it's already running now opens the surface in the browser, so the app is still reachable with no icon.
LanAccessindeckd/macos_app.pywraps the user default, so it's unit-tested on Linux.menubar.pyreads it at launch, sets the ✓ from it, and saves on toggle.test-app.shclears the saved choice before the "refused by default" check, then checks that it's saved and survives a quit and relaunch.Verification:
pytestpasses (777 passed, 103 skipped). I built the app locally withjust build-macos-appand set only thedefaults writeabove. On launch it listened on*:8765, the LAN hostname returned 200, and the menu showed ✓. I didn't runtest-app.shlocally because it replaces/Applications/deckd.app; thetest-appCI job covers it.Not fixed here: the invisible icon is macOS state, not a deckd bug. An identical build relabelled
com.deckd.probeplaced its icon normally, whilecom.deckd.daemonstays off-screen even though it's allowed in System Settings → Menu Bar. Renaming the status item didn't help.Created with Claude Opus 5.5 in Claude Code.
🤖 Generated with Claude Code