Skip to content

Fix shell restart race through launcher ownership - #7546

Draft
Skeptomenos wants to merge 1 commit into
omacom:quattrofrom
Skeptomenos:fix/quickshell-restart-race
Draft

Skeptomenos wants to merge 1 commit into
omacom:quattrofrom
Skeptomenos:fix/quickshell-restart-race

Conversation

@Skeptomenos

Copy link
Copy Markdown
Contributor

Summary

  • stop every matching omarchy-launch-shell supervisor before launching a replacement
  • wait for each supervisor and its Quickshell child to exit
  • remove the restart path's dependency on version-specific quickshell kill behavior
  • cover asynchronous Quickshell shutdown and duplicate launcher replacement in the restart regression test

Root cause

omarchy-restart-shell repeatedly called quickshell kill until no instance matched. Stock Quickshell 0.3 returns before QML teardown is complete. Its development fix waits for IPC disconnect, but disconnect is still not a process-ownership boundary.

A second stop request or replacement launch can therefore overlap teardown. On an ARM system this produced a Quickshell SIGSEGV during omarchy update. The surviving supervisor relaunched its child while the update launched another supervisor, which left two shells and two bars.

The launcher already owns the child lifecycle and waits for the child it terminates. This change uses that ownership boundary directly.

This addresses the restart race described in #7076. It does not claim to fix the separate cold QML compilation and readiness concerns in that issue.

Validation

  • focused restart suite: 7/7 passed
  • ./test/all: all 184 current test files passed
  • bin/omarchy commands --check: 428 commands passed
  • shell and Python syntax checks passed
  • live ARM verification after deployment: one launcher, one Quickshell process, and no new core dump

@omarchybot

Copy link
Copy Markdown
Collaborator

Following the merge of #11015, The five-second slow-exit race is covered, but this PR changes supervisor ownership to handle crashes/overlapping children during teardown. That distinct lifecycle change is not in the merged performance fix; keep it open for its remaining scope.

Scope checked by GPT-6 in Codex and Codex Medium against the discussion and landed change; review independence is not guaranteed. No tests were rerun for this cleanup.

Omabot on behalf of DHH

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants