Skip to content

Start the Touch Bar renderer with every graphical session - #53

Open
niconistal wants to merge 1 commit into
standardagents:mainfrom
niconistal:touchbar-wanted-by-graphical-session
Open

niconistal wants to merge 1 commit into
standardagents:mainfrom
niconistal:touchbar-wanted-by-graphical-session

Conversation

@niconistal

Copy link
Copy Markdown
Contributor

Problem

t1-touchbar.service is PartOf=graphical-session.target, so a logout stops it, but it is only WantedBy=default.target, which a user manager reaches once. When the manager outlives the logout because another session of the same user keeps it alive (an SSH session, for example), the next login never starts the renderer again. The hardware service keeps the last frame on the panel, so the Touch Bar looks alive, but no press reaches anything. journalctl -u t1-touchbar-hw ends with phase=session-revocation and no later session-admission; systemctl --user status t1-touchbar.service shows inactive (dead) since the logout.

Change

Add graphical-session.target to the unit's WantedBy, so each graphical session starts the renderer and PartOf stops it, symmetrically. A fresh user manager still starts it from default.target as before, so the early-start behaviour discussed in #35 is unchanged by this PR. docs/setup.md notes that installs enabled before this change need one systemctl --user enable t1-touchbar.service to add the new link (upgrades do not re-run user presets).

No code changes; unit and docs only.

Testing

  • systemd-analyze --user verify systemd/user/t1-touchbar.service passes.
  • Hardware: MacBookPro14,3, Omarchy 4.0.4, t1bridge 0.1.12. Reproduced over four logout/login cycles with a surviving user manager: renderer dead after each login, Touch Bar lit and unresponsive. With the graphical-session.target.wants link in place (systemctl --user add-wants graphical-session.target t1-touchbar.service, equivalent to this unit change), the renderer starts at login, the hardware service logs session-admission result=ok, and presses work.
  • Doc change checked for links and command syntax; no package rebuild needed.

Related to #35.

🤖 Generated with Claude Code

t1-touchbar.service is PartOf=graphical-session.target, so a logout stops
it, but it is only WantedBy=default.target, which a user manager reaches
once. When the manager outlives the logout because another session of the
same user keeps it alive (an SSH session, for example), the next login
never starts the renderer again: the hardware service keeps the last frame
on the panel, so the Touch Bar looks alive, but no press reaches anything.
The hardware service log ends at session-revocation with no later
session-admission.

Also want the unit from graphical-session.target, so each graphical
session starts it and PartOf stops it, symmetrically. A fresh manager still
starts it from default.target as before. Installs enabled before this
change need one `systemctl --user enable t1-touchbar.service` to add the
new link; the setup guide says so.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

This branch has not been deployed

No deployments
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.

1 participant