fix: keep sync-state from masking relayouts #152

Merged
barrettruth merged 1 commit from fix/sync-state-fingerprint-race into main 2026-05-02 20:01:52 +00:00
Owner

Summary

  • track whether _sync-state actually changed @mosaic-mfact
  • avoid publishing a completed fingerprint from _sync-state when that option write must be followed by the after-set-option relayout
  • wait for ownership/fingerprint state to settle before raw managed split suspension assertions
  • make new-pane acceptance setup force a deterministic relayout after multi-option setup
  • preserve fingerprint finalization for no-op sync-state paths such as unsupported/zoomed syncs

Verification

BATS_JOBS=1 direnv exec /home/barrett/dev/tmux-mosaic just test-one 'drag-resize: master width survives next split'
BATS_JOBS=4 direnv exec /home/barrett/dev/tmux-mosaic just test-one 'drag-resize|no double relayout: drag-resize sync triggers at most one relayout|sync short-circuit: drag-resize whose pct is unchanged does not write @mosaic-mfact|monocle: _sync-state stays silent when unsupported'
BATS_JOBS=1 direnv exec /home/barrett/dev/tmux-mosaic just test-one 'auto-apply managed: raw split-window -h suspends the window|auto-apply managed: raw split-window -v suspends the window|auto-apply managed: dead foreign panes with remain-on-exit stay suspended until removed'
BATS_JOBS=4 direnv exec /home/barrett/dev/tmux-mosaic just test-file new_pane_acceptance.bats
BATS_JOBS=4 direnv exec /home/barrett/dev/tmux-mosaic just test-one 'drag-resize: master width survives next split|auto-apply managed: raw split-window -v suspends the window|new-pane acceptance: master-stack right all-masters transition compresses masters into the right branch while the new pane stays left'

Repeated targeted filters:

  • drag-resize: master width survives next split: 10/10 passed
  • auto-apply managed: raw split-window -v suspends the window: 10/10 passed
direnv exec /home/barrett/dev/tmux-mosaic just format
direnv exec /home/barrett/dev/tmux-mosaic just lint
git diff --check

Full Bats suite intentionally not run locally; this fixes timing-sensitive paths with targeted coverage only.

## Summary - track whether `_sync-state` actually changed `@mosaic-mfact` - avoid publishing a completed fingerprint from `_sync-state` when that option write must be followed by the after-set-option relayout - wait for ownership/fingerprint state to settle before raw managed split suspension assertions - make new-pane acceptance setup force a deterministic relayout after multi-option setup - preserve fingerprint finalization for no-op sync-state paths such as unsupported/zoomed syncs ## Verification ```sh BATS_JOBS=1 direnv exec /home/barrett/dev/tmux-mosaic just test-one 'drag-resize: master width survives next split' ``` ```sh BATS_JOBS=4 direnv exec /home/barrett/dev/tmux-mosaic just test-one 'drag-resize|no double relayout: drag-resize sync triggers at most one relayout|sync short-circuit: drag-resize whose pct is unchanged does not write @mosaic-mfact|monocle: _sync-state stays silent when unsupported' ``` ```sh BATS_JOBS=1 direnv exec /home/barrett/dev/tmux-mosaic just test-one 'auto-apply managed: raw split-window -h suspends the window|auto-apply managed: raw split-window -v suspends the window|auto-apply managed: dead foreign panes with remain-on-exit stay suspended until removed' ``` ```sh BATS_JOBS=4 direnv exec /home/barrett/dev/tmux-mosaic just test-file new_pane_acceptance.bats ``` ```sh BATS_JOBS=4 direnv exec /home/barrett/dev/tmux-mosaic just test-one 'drag-resize: master width survives next split|auto-apply managed: raw split-window -v suspends the window|new-pane acceptance: master-stack right all-masters transition compresses masters into the right branch while the new pane stays left' ``` Repeated targeted filters: - `drag-resize: master width survives next split`: 10/10 passed - `auto-apply managed: raw split-window -v suspends the window`: 10/10 passed ```sh direnv exec /home/barrett/dev/tmux-mosaic just format direnv exec /home/barrett/dev/tmux-mosaic just lint git diff --check ``` Full Bats suite intentionally not run locally; this fixes timing-sensitive paths with targeted coverage only.
fix: keep sync-state from masking relayouts
Some checks failed
Request Review / request_review (pull_request_target) Successful in 6s
quality / Format (pull_request) Successful in 9s
quality / Lint (pull_request) Successful in 12s
quality / Test (pull_request) Failing after 2m56s
Release Metadata / release_metadata (pull_request_target) Successful in 3s
2dbed8aaca
barrettruth force-pushed fix/sync-state-fingerprint-race from 2dbed8aaca
Some checks failed
Request Review / request_review (pull_request_target) Successful in 6s
quality / Format (pull_request) Successful in 9s
quality / Lint (pull_request) Successful in 12s
quality / Test (pull_request) Failing after 2m56s
Release Metadata / release_metadata (pull_request_target) Successful in 3s
to 8f511ac4f9
Some checks failed
Request Review / request_review (pull_request_target) Successful in 2s
quality / Format (pull_request) Successful in 8s
quality / Lint (pull_request) Successful in 12s
quality / Test (pull_request) Failing after 2m37s
Release Metadata / release_metadata (pull_request_target) Successful in 3s
2026-05-02 19:52:16 +00:00
Compare
barrettruth force-pushed fix/sync-state-fingerprint-race from 8f511ac4f9
Some checks failed
Request Review / request_review (pull_request_target) Successful in 2s
quality / Format (pull_request) Successful in 8s
quality / Lint (pull_request) Successful in 12s
quality / Test (pull_request) Failing after 2m37s
Release Metadata / release_metadata (pull_request_target) Successful in 3s
to d128fb412c
All checks were successful
Request Review / request_review (pull_request_target) Successful in 2s
Release Metadata / release_metadata (pull_request_target) Successful in 3s
quality / Format (pull_request) Successful in 8s
quality / Lint (pull_request) Successful in 11s
quality / Test (pull_request) Successful in 2m40s
2026-05-02 19:57:40 +00:00
Compare
Sign in to join this conversation.
No description provided.