Skip to content

chore(upstream-sync): port 1 t3code commit - #460

Merged
trancong12102 merged 2 commits into
mainfrom
chore/upstream-sync-20261120-0607
Nov 19, 2026
Merged

trancong12102 merged 2 commits into
mainfrom
chore/upstream-sync-20261120-0607

Conversation

@trancong12102

Copy link
Copy Markdown
Contributor

Ports 1 t3code commit: shell item counts read a per-thread total instead of summing every run.

Risky

  • 2bba2564ca perf(server): thread shell item counts no longer sum every run the thread has had [risky: migrations]. Upstream migration 102 → Onicode 107 (next free); test toMigrationInclusive 106, reconcileV2PreviewMigration.test.ts rows, comments name Onicode 091 (upstream 085, TurnItemCounts). No Onicode-only writer of the count tables found outside the triggers. ProjectionStore query merged cleanly (Onicode had upstream's previous query unchanged).

Routine

None.

Adopt or keep

  • adopted upstream's shell item count read over Onicode's previous one: Onicode's was upstream's old query unchanged; the new one visits only hidden runs instead of every run the thread has had.

Skipped

None.

E2E

No scenario changes in this commit.

Follow-ups

  • None queued; no batch thread launched. Other-provider bugs left to upstream: none.
  • Doc follow-up done here: docs/internals/performance-regressions.md now says shell counts read a per-thread total (Claude's nit).

Review findings

  • Claude Opus: no adaptation or fork bugs; traced Onicode-only writers (migrate-dev-db copy/prune order, replay testkit, earlier migrations 091–106) and found the totals stay exact. Doc nit fixed.
  • Codex gpt-6.2-astra: no adaptation defect. Two upstream-as-written cases, both needing a turn item whose run belongs to another thread: (P2) a rolled-back run on another thread is no longer subtracted from the item's thread; (P3) migrate-dev-db could copy a stale total when the item's run is on an excluded thread. Claude raised the first as theoretical too. Dismissed: no writer produces such rows (subagent results are written on the parent thread with the parent run) and the live database has 0 of 259,587 run-bound items on a different thread than their run.

Done with Claude Opus 5.5 in Claude Code, reviewed by Codex gpt-6.2-astra and Claude Opus 5.5.

🤖 Generated with Claude Code

juliusmarminge and others added 2 commits November 20, 2026 06:09
…read has had (#39391)

Ported from pingdotgg/t3code@2bba2564ca. The migration takes Onicode's next free number, 107, and its comments name Onicode migration 91 (upstream 85, the same TurnItemCounts).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Follow-up to the port of t3code@2bba2564ca.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@trancong12102
trancong12102 merged commit b001fb8 into main Nov 19, 2026
17 checks passed
@trancong12102
trancong12102 deleted the chore/upstream-sync-20261120-0607 branch November 19, 2026 23:21
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.

2 participants