Skip to content

fix(vcs): list-mode status without remote pollers for row UIs - #170

Merged
patroza merged 2 commits into
fork/changesfrom
t3code/vcs-list-mode-no-poller
Jul 29, 2026
Merged

fix(vcs): list-mode status without remote pollers for row UIs#170
patroza merged 2 commits into
fork/changesfrom
t3code/vcs-list-mode-no-poller

Conversation

@patroza

@patroza patroza commented Jul 29, 2026

Copy link
Copy Markdown
Owner

Summary

Structural fix for the VCS storm root cause — without dropping live PR/git freshness on list UIs.

Problem

Every sidebar/board row used full subscribeVcsStatusone remote poller fiber per worktree → O(N) git/fetch/gh → thrash → disconnects. That model is upstream; fork amplifies via board.

What we do not do

We do not leave list rows one-shot/stale. PR badges and remote state stay up to date.

Structural model

Mode Surfaces Behavior
list Sidebar, Sidebar V2, thread rows, board, mobile thread PR Local status + shared budgeted remote refresher for all list-interested cwds (60s cadence, concurrency 2, no git fetch on sweep). No per-cwd poller.
full Chat, Diff, Git actions, branch toolbar, … Dedicated per-cwd poller (existing automatic fetch interval).

List subscribers still receive pubsub updates when the shared sweep (or a full subscriber / explicit refresh) updates their cwd.

Details

  • Contract: optional VcsStatusInput.mode: "full" | "list"
  • Client: vcsEnvironment.listStatus (forces list, 60s idle TTL)
  • Full poller still wins for a cwd that has both modes (list sweep skips those)

Tests

  • Shared refresher covers two list cwds without 30s per-cwd cadence
  • Schema + existing broadcaster suite

Test plan

  • Unit tests (list shared refresher)
  • Typecheck / format
  • Deploy: many worktree rows → PR badges still update; Jaeger shows one list sweep fiber pattern, not N× retainRemotePoller storms

github-actions Bot added 2 commits July 29, 2026 11:31
Break the O(N) always-on VCS poller model for sidebar/board/thread lists:
subscribe with mode=list loads local (+ one coalesced remote) but does not
retain the automatic remote poller. Active git chrome keeps full mode.
List mode no longer drops live remote/PR updates. A single shared sweep
refreshes all list-interested worktrees on a 60s cadence with concurrency 2,
skipping cwds that already have a full-mode poller. Per-row 30s pollers stay
gone so O(N) storms do not return.
@patroza
patroza force-pushed the t3code/vcs-list-mode-no-poller branch from 61e4809 to 825db39 Compare July 29, 2026 09:32
@patroza
patroza merged commit 7b3e7e5 into fork/changes Jul 29, 2026
11 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