Repository navigation
Fix/checkpoint diff unavailable - #259
paddybuilds wants to merge 2 commits into
Conversation
|
@paddybuilds is attempting to deploy a commit to the Ping Labs Team on Vercel. A member of the Team first needs to authorize it. |
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Tip Try Coding Plans. Let us write the prompt for your AI agent so you can ship faster (with fewer bugs). Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f7af0ec8f5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (input.fromTurnCount > 0 && fromCheckpoint && fromCheckpoint.status !== "ready") { | ||
| return yield* emptyTurnDiffResult(input.fromTurnCount, input.toTurnCount); |
There was a problem hiding this comment.
Keep missing-base checkpoint as unavailable
When getTurnDiff sees a missing fromCheckpointRef and the source checkpoint is non-ready, it now returns diff: "" instead of an error. This turns an unavailable diff into a false “no changes” result for ranges like fromTurnCount=1,toTurnCount=2 after an interrupted/legacy turn where turn 1 has no filesystem ref but turn 2 does, so the UI can incorrectly report no net changes rather than surfacing that the base checkpoint is missing.
Useful? React with 👍 / 👎.
Merges `pingdotgg/t3code` `7510e5e43c` into the fork. The base is `b808f7fc6d` and the range is 201 commits. This branches from `main`; no other merge PR is open. ## What the merge did - **Settings moved under `_chat`.** Upstream moved every `routes/settings.*` route under the `_chat` layout, so settings is now a modal over the app. Before merging, I re-pointed the three inventory entries that named those paths. The fork's `settings.version-control.tsx` moved to `_chat.settings.version-control.tsx`. The auth redirect now lives only in `_chat.tsx`, which already sends a signed-out viewer to `/login`. `_chat.settings.tsx` keeps only the `settingsPathEnabled` redirect. - **14 conflicts**, each resolved by the verdict preflight printed. The decisions are in the `docs/fork/upstream-merge-log.md` entry. The ones worth reviewing: - `ProviderInstanceCard.tsx`: upstream's redesign adds a separate Status row. When `providerConfiguration` is off that row is suppressed, and the display-name row stays the Status row with `ProviderAuthAction`. - `projectScriptEditor.tsx`: the fork's `port` field now follows upstream's form-per-request state. - `useChatTerminalActions.ts`: the host-run script path now focuses with upstream's `focusTerminal`. - `FilePreviewPanel.tsx`: both sides kept. Upstream now has its own `binary_file` download; I added convergence entry `workspace-binary-download` for it. - **New upstream lint rule `t3code/react-effect-budget`.** It counted 19 effects that the fork already had. Each now has a justified `oxlint-disable-next-line` comment. I did not edit upstream's `scripts/effect-budget.json`, so the fork adds no delta to that file. - **Inventory updates.** - Two new path-policy entries: `chat-terminal-actions` and `terminal-metadata-scan`. - One replaced `duplicateAddExceptions` entry. - `orchestration.getOlderSettledThreads` now declares `UnsupportedMethodError`. Checked against the backend source: Moatless does not dispatch it. - **Merge fixes.** - Mobile `ThreadTerminalRouteScreen.tsx` now reads the fork's `TerminalMetadataState`. - `fork/features.test.ts` now reads the moved route sources. **File counts:** - 1230 files landed (`HEAD^1..HEAD`), against 1215 in the upstream range. Every upstream file landed; the 15 extra are fork files this merge edited. - The fork delta is 758 files (`HEAD^2..HEAD`), up one from 757 because of the moved route. ## Verification `verify.mjs` full run. These checks are green: duplicate-adds, tripwires, resolution-check, unsupported-methods, lockfile, fmt, lint, typecheck and build. `tripwires` and `unsupported-methods` passed on a rerun; on the first run they failed only because the Moatless proxy and api.github.com were unreachable. Tests: - Every other package passes. - `t3` and `provider-opencode` fail the same six files the 2026-10-25 merge recorded. One of them is the registered `/tmp` sticky-bit gap. - `@t3tools/web` needs the same Playwright browser alias as last merge (headless-shell build 1223 pointed at 1243). With that, 404/405 files pass; `AttachmentFilePreview.browser.test.tsx`'s Word render tests (new upstream) time out at 15s in the package run and pass as a single file. ## Upstream features ### Usable as-is - Settings and Usage open as large modals over the thread (pingdotgg#24847). - New design (Beta), behind the `redesignEnabled` client setting (pingdotgg#24865, pingdotgg#25251). The Moatless settings store must persist the key. - The sidebar Working section is on by default (pingdotgg#25190). - File previews: - Office files, fonts and mermaid diagrams (pingdotgg#21362). - Archives, SQLite databases and images (pingdotgg#21467). - OpenDocument, epub and notebooks (pingdotgg#21469). - Virtualized large previews (pingdotgg#21466). - Inline audio (pingdotgg#21363) and SVG attachments (pingdotgg#21355). - The command palette searches inside submenus (pingdotgg#24709). - Smaller web fixes: - The usage-limit banner follows the Time format setting. - Snooze is disabled at the reset time. - Question options show a radio button and a shortcut key. - Terminal drag-selection scrolls. - Queued-edit fixes and PR checks refresh. - Mobile UI: - iOS resizable inspector (pingdotgg#24985). - Settings search (pingdotgg#24766). - Duo fold fixes. - Android dialogs raised during activity replacement now show (pingdotgg#25229). - Desktop only: Zen Browser cookie import, and hidden preview tabs are throttled. ### Unsupported in Moatless / needs implementation - **Older settled threads paged out of the shell** (pingdotgg#24723). - Method: `orchestration.getOlderSettledThreads`. - Contract fields: `omitOlderSettled` on the shell snapshot input, `olderSettled` on its reply, `olderSettledBefore` on thread search. - Capability: `shellOlderSettled`, which requires `shellThreadFamilies`. - Files: `packages/contracts/src/{rpc,orchestrationV2,server,environmentHttp}.ts`, upstream `apps/server/src/orchestration-v2/ShellStream.ts`. - The client asks only when the capability is advertised, so Moatless currently gets full snapshots. Added to the gaps register. - **On-demand provider workspace snapshots.** `workspaceSnapshotsOnDemand` and `usageLimitsCommand` on `server.refreshProviders` and `subscribeServerConfig`. Optional; older servers send full snapshots. - **`vcs.status` `localOnly`**, which skips the remote lookup. Optional. - **Asset `disposition: "attachment"`.** Needs a `Content-Disposition` response. Moatless serving it is what would retire `WorkspaceBinaryFile` (convergence entry `workspace-binary-download`). - **`request_secret` with `delivery: "file"`** and the `not_a_file_request` error (pingdotgg#24809, `secretRequest.ts`). - **Reworked agent MCP contracts:** `orchestratorMcp.ts`, `worktreeMcp.ts`, `scheduledTask.ts` and `previewAutomation.ts`. Thread tools now return a `t3-thread` link (pingdotgg#24784), and PR-watch tools are hidden from delegated children (pingdotgg#24808). - **PDF attachments sent to Claude as documents**, with document text extraction (pingdotgg#21358, pingdotgg#21458). ### Backend behavior to consider reproducing in Moatless - **Delegated runs.** - The parent is notified when a delegated background run finishes (pingdotgg#23542). - Agents are told to end the turn while delegates run (pingdotgg#24887, pingdotgg#24782). - Background compactions no longer flip a thread to Working (pingdotgg#25122). - **Thread lifecycle.** - Ended root threads stop their provider turns (pingdotgg#22846). - A thread settles right after a shell merge of an unlinked PR (pingdotgg#24830). - Forked threads take titles from the history they inherit (pingdotgg#24857). - **Pull requests.** - Links agents create from the shell are picked up (pingdotgg#24813, `PullRequestSyncReactor.ts`). - The timeline and search are faster (pingdotgg#22697). - **Scripts.** Worktree setup no longer hangs when a shell startup prompt eats the command (pingdotgg#24775, `ProjectSetupScriptRunner.ts`). - **Persistence.** - Superseded turn-item snapshots are compacted (pingdotgg#20990). - Committed events are published before writer cancellation (pingdotgg#24836). - Opening a thread loads 85% less data (pingdotgg#24899). - **Providers.** - Codex native collaboration modes (pingdotgg#24737). - Instructions are 60% smaller (pingdotgg#24850). - Attachments are no longer silently dropped from prompts (pingdotgg#21356). The gaps register's "Runtime fixes upstream made to its own server" entry is extended with these. ## Sweep 28 new upstream files matched the owned-concern pattern: `infra/task-cache` and its vendored remote cache, `cloudAccountService`, and mobile audio and permission files. None is part of the web surface the fork ships, so all were taken as upstream's. No new workflows. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- Moatless task: https://moatless.soaplabstest.com/tasks/53d246c0-4228-43a3-b92f-5272c5e2fd8e
Fixed checkpoint diffs being unavailable
The issue was caused by a mismatch between projected checkpoint metadata and actual git-backed filesystem checkpoints
Note
Return an empty diff in
CheckpointDiffQuery.getTurnDiffwhen a non-ready checkpoint ref is unavailable to fix the checkpoint diff unavailable issue, and ingestturn.diff.updatedas activities withdiffBytesin ProviderRuntimeIngestion.tsUpdate
getTurnDiffto emit an empty result for missing non-ready checkpoints and addturn.diff.updatedactivity ingestion withdiffBytes; adjust tests and remove checkpoint creation on diff updates. See CheckpointDiffQuery.ts and ProviderRuntimeIngestion.ts.📍Where to Start
Start with the
getTurnDiffhandler in CheckpointDiffQuery.ts, then reviewruntimeEventToActivitiesin ProviderRuntimeIngestion.ts.Macroscope summarized f7af0ec.