Skip to content

fix(ios): the Watch lists a session once when two paired servers report it - #642

Merged
jonwiggins merged 1 commit into
mainfrom
fix/ios-watch-dedupe
Oct 6, 2026
Merged

jonwiggins merged 1 commit into
mainfrom
fix/ios-watch-dedupe

Conversation

@jonwiggins

Copy link
Copy Markdown
Owner

Summary

  • NeedsYouSnapshot.merge dedupes items by id (first copy wins; needs-you beats running).
  • loadAll merges servers in configured order (active first) instead of completion order, so the kept copy is the active server's.
  • WatchMergeTests covers the three cases.

Test plan

  • OptioTests Watch* suites pass on the iPhone 17e simulator (22 tests)

…rt it

Two paired entries that reach the same Optio (a LAN address and a Tailscale
name, an old pairing never removed) each reported every running terminal and
every followed task, and the merged snapshot concatenated them, so the Live
Activity and widgets listed the same session two or more times. The merge now
keeps the first copy of each id — the active server's, since servers now
merge in their configured order rather than in the order they answered —
and an item that needs you is never also counted as running.
@jonwiggins
jonwiggins merged commit c7d6039 into main Oct 6, 2026
13 checks passed
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