Repository navigation
chore(sync): absorb upstream main through ad2bdc76a5 - #402
Conversation
…dotgg#30925) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…ingdotgg#39670) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…t page by default (pingdotgg#40003) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…hanges (pingdotgg#24841) Co-authored-by: maria-rcks <maria@kuuro.net> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…tgg#24888) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…s current (pingdotgg#36868) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…checkout (pingdotgg#37191) Co-authored-by: Julius Marminge <julius0216@outlook.com>
… errors (pingdotgg#40042) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…ingdotgg#39994) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…nvironment inputs (pingdotgg#39992)
…Button, and ControlPill (pingdotgg#40002)
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
pingdotgg#40133) Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
…40020) Co-authored-by: Simone <185146821+Lucenx9@users.noreply.github.com> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…asked for a result (pingdotgg#40137) Co-authored-by: MarcoDotIO <Marcus.Arnett10@gmail.com>
…ingdotgg#40072) Co-authored-by: Julius Marminge <julius0216@outlook.com>
…ding (pingdotgg#39989) Co-authored-by: Julius Marminge <julius0216@outlook.com>
pingdotgg#27391) Co-authored-by: Enmani <43571965+Enmani@users.noreply.github.com> Co-authored-by: Julius Marminge <julius0216@outlook.com>
…on (pingdotgg#21667) Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Wout Stiens <71498452+StiensWout@users.noreply.github.com> Co-authored-by: Julius Marminge <julius0216@outlook.com>
Merges 2,023 upstream commits (5cbdf00..ad2bdc7). 75 files conflicted. Fork adaptations: - Crew rules: upstream's thread.create now carries the first message, so the bot is resolved before the create (forkBotIdFor) and CREW.md rides it. - Branch follow: the finalize refresh runs in upstream's background fiber; the fork's follow rides the same fiber. - SSH remotes: the archive-version fence moves to DesktopSshEnvironment.ts. - i18n: upstream translated the app. Fork copy stays English: the no-untranslated-copy rule is deferred in fork paths (baseline 884), and i18n:check keeps en.json keys for upstream copy the fork removed (new fork-i18n-catalog customization and guard). - Retired: the budget-gate BASE_REF fence (upstream reads HEAD^1) and the unenv pin (upstream carries the same override). - Stores: closed-view and right-panel storage versions bumped past upstream's so fork stores migrate again. - Ported upstream behaviour into fork surfaces: override shadows, the subagent card's open intent, the touch keyboard fix in the model picker, the schedule label's timestamp format, and nine new Hugeicons mappings. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Plain-folder projects with tracked repositories get upstream's workspace mode selector in the composer; Git roots keep the fork's combined picker. - A shared-checkout thread adopts its branch before finalization returns, so its next queued turn cannot start first and win the follower's run guard. Other threads keep upstream's background refresh. - Subagent cards open remote tasks through upstream's linked-thread opener, honour read-only timelines, and offer the side panel only where it opens. - i18n:check keeps removed-copy keys for apps/web only. - fork-storybook's tsconfig gains ES2024.Promise, matching web. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Found by a Gemini 4 Neon review of the upstream merge. - Pending-question digit shortcuts ignore keys already handled and keys typed in menus, dialogs and popups, as upstream's panel does. - The queued-runs banner no longer steers a /clear-armed message into the running turn (the server refuses it) and toasts a failed send. - The folded live status line shows upstream's "Waiting on N subagents" label and resolves tool labels in the UI language. - A bot's working state no longer depends on the UI language. - The Scheduled page locks the model for a task bound to a thread. - The usage limits view resolves its notices in the UI language. - canFollow re-raises interruption instead of reading it as false. - Corrected the notes on why upstream's keyboard thread-menu test is not ported: the fork's cards never installed upstream's sidebar tree. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Keeps the fork's branch-link copy beside upstream's translated "Copy branch name" label, passes copyBranchReference a clipboard target object, and moves the deferred untranslated-copy count to 890 for the six English strings custom added meanwhile. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
This PR changes the test suite by +3463 test cases (browser +234, unit +2231, server +998). New browser test files: Keep tests that would fail for a real reason, and test logic below the UI where it can be. See Testing. |
NoahHendrickson
left a comment
There was a problem hiding this comment.
Reviewed 8e8075d344804a16f30b016e3494e5ebe182ee9c against 84afbb479a223d27b63ee381eef26187306f3e95. I found two regressions in the server paths for scheduled worktrees and Petal work threads. This was a targeted source review of the sync. I did not run the PR code locally.
| const workspaceStrategy: ScheduledTask["workspaceStrategy"] = | ||
| input.workspaceStrategy.type === "worktree" && | ||
| (yield* managedFolders.isScratchProject(input.projectId)) | ||
| ((yield* managedFolders.isScratchProject(input.projectId)) || | ||
| (yield* threadLaunch.isNonGitProject(input.projectId))) |
There was a problem hiding this comment.
[P2] Keep worktree launches for projects that track Git repositories
isNonGitProject only checks project.workspaceRoot. A plain project folder with tracked Git repositories can still create a task folder with worktrees through TaskFolders.plan, including when the caller explicitly passes workspaceStrategy.repositories. Saving a task for that project now silently changes its strategy to root and discards the repository selection. The next unbound run uses the shared checkout even though the user selected a worktree. Check whether the project can create a task folder before falling back to root.
There was a problem hiding this comment.
Not from this sync: this line is upstream's, byte-identical to upstream main (ScheduledTaskService.ts:1583 there). The fork doesn't change upstream behaviour in a sync, so I'm leaving it as is. If it's a bug, it belongs upstream.
| @@ -3033,17 +3361,18 @@ const make = Effect.gen(function* () { | |||
| ...(parent.thread.linkOrigin === undefined | |||
| ? {} | |||
| : { linkOrigin: parent.thread.linkOrigin }), | |||
| ...(initialMessage === undefined ? {} : { initialMessage }), | |||
There was a problem hiding this comment.
[P2] Persist Petal ownership before the first provider turn can start
Passing initialMessage here commits a provider start effect in the same transaction as thread.create. The worker can pick it up before the later linkForkBotWork dispatch commits the bot-work tag. If the provider fails at startup in that window, ForkBotWorkReports sees no owner and permanently skips the failure report. The base tagged the thread before dispatching its first message. Preserve that ordering for Petal work or write the tag in the creation transaction.
There was a problem hiding this comment.
Real, but narrow. Bot-work reports read the tag when the failure event arrives, and the tag is dispatched right after thread.create commits. So only a provider that fails during startup, inside that gap, loses its report. Closing the gap means thread.create has to carry the tag, which is a contract and orchestrator change. That's more than a sync should make, so it stays a listed follow-up for the maintainer to decide.
NoahHendrickson
left a comment
There was a problem hiding this comment.
Thermo-nuclear code-quality review: 8e8075d344
Scope: an upstream sync is mostly upstream code that isn't the fork's to restructure. So I reviewed the fork-authored resolution work: the two fix(sync) commits, plus the 108 files whose fork delta changed between the old and new upstream base.
File size: no file crosses 1k lines because of this PR. The fork deltas in ChatComposer, ChatView, ThreadLaunchService and OrchestratorMcpService stayed about the same size.
Verdict: not approvable as is. The most important finding is #1: it's a live perf regression against upstream, and it shows why copying upstream components keeps going wrong. The other findings keep logic in two places, or patch over a boundary that should be made explicit.
1. ForkQueuedRunsBanner is a hand copy of upstream's QueuedRunsControl, and the copy is already behind (perf regression)
This sync ported upstream's fresh-context steer rule and failure toast into the fork banner by copying them line for line. It missed two other upstream changes to the same file in the same window:
- pingdotgg#24055 switched
QueuedRunsControltouseQuietThreadProjectionso it "no longer re-renders on every streamed token". The fork banner still callsuseThreadProjection. It's the only fork component that does, so it re-renders on every token while a turn streams. - pingdotgg#37893 passes
messagestoderiveThreadQueueWorkflowState, so the labels follow the UI language. The fork calls it withoutmessages, both at line 80 and at line 136.
The root problem is structural: the queue model (items, canSendRun, sendQueuedMessage and its toast, steerNext) lives in two component bodies, and every sync relies on someone noticing upstream changed. Gemini already had to find three of these drifts by hand for this PR.
Proposed fix: move the non-visual queue model into one fork hook whose only job is to track upstream's QueuedRunsControl (or upstream a useQueuedRunActions hook). Then the banner is presentation plus drag-reorder, and a sync diff lands in exactly one file.
Also, at apps/web/src/custom/ForkQueuedRunsBanner.tsx:623, canSendRun now also returns false for a /clear-armed message while a steerable run is active. In that case the tooltip says "There is no active run to steer", which isn't the reason. Upstream hides the button in this state.
Locations: apps/web/src/custom/ForkQueuedRunsBanner.tsx:108 (projection hook) and :136 (messages dropped). This file and botWork.ts are past GitHub's 3,000-file PR diff limit, so they can't take inline comments.
2. Bot resolution now runs twice per launch
The new forkBotIdFor repeats the forkBotActingShell → launcherBotId walk that linkForkBotWork already does. Both ThreadLaunchService.launch and MCP create_threads now run both, which means up to four getThreadShell reads. The botId that linkForkBotWork returns is now ignored at both call sites. ThreadLaunchService also checks launchedBy !== undefined && reuseExistingThread !== true twice.
Proposed fix: resolve once, then use that result for both the crew rules and the tag. Make linkForkBotWork take a resolved botId and return void. That removes the duplicate walk, the duplicated condition, and the dead return value.
3. canFollow adds a second copy of the follow-eligibility rule and splits upstream's finalize into two paths
canFollow copies part of followLocalCheckoutBranch's guard (worktreePath === null && branch !== null) in a second place, with a second shell read. Upstream's finalize now has an inline-or-background branch that depends on it. The inline arm also waits on the whole display refresh: workspaceEntries.refresh (the workspace rescan), identity probing, and the PR lookup that kicks off. But the follow only needs the refreshLocalStatus result. So every shared-checkout thread gets back the latency that upstream moved off the critical path.
Proposed fix: give the follower one way to decide, either a shared isSharedCheckoutThread(shell) predicate or a single followInline method, and wait only on status + follow. The workspace rescan stays on upstream's FiberSet. That deletes most of the fork's branching in finalize. The as unknown as VcsStatusLocalResult cast in the new test also hides which fields the follower actually reads.
4. BranchToolbar: the fix copies upstream's selector into the fork fence instead of narrowing the fence
The fork-composer-shell fence already covers upstream's environment selector, the WorktreeRepositoriesControl and the plain-folder copy. This fix pastes BranchToolbarEnvModeSelector's eight workspace-mode props into the fence, and the same eight props are passed again to ComposerWorkspaceFooter a few lines below.
Upstream already renders the selector under showGitControls. The smaller change is to keep upstream's render where it is and fence only its condition (showGitControls && !showBranchControls). Then shrink the fence to the branch-selector arm, the only place the fork actually differs, and bundle the workspace-mode props into one object used by both. Then the next upstream change to this block doesn't conflict with the fork.
5. botWork.isRunning (apps/web/src/custom/bots/botWork.ts:94) gets "is it working" by comparing translated strings
resolveWindowTitleThreadStatus(thread, m) === m(THREAD_STATUS_TEXT.working) translates a typed status into display text and compares the text to get the status back. The fix made both sides use the same language, but the coupling to the copy is still there. Switch on resolveSidebarThreadStatus({ ...thread, pendingGuestMessageCount: 0 }) directly (preparing | working, or waiting with runtime.status === "running"). That's the rule the window title uses, without going through copy.
No blocking issues in i18n-check.ts, the lint-ratchet deferral, ForkSubagentGroup's move to useLinkedThreadOpener, or the pending-input key guard. They're direct and scoped.
Reviewed commit: 8e8075d344804a16f30b016e3494e5ebe182ee9c (base 84afbb479a).
🤖 Signed: Claude Opus 5.5 (claude-opus-5-5) via Claude Code
| @@ -45,6 +45,18 @@ function launcherBotId(launcher: Pick<OrchestrationV2ThreadShell, "id" | "tags"> | |||
| return forkBotWorkTag(launcher.id).length <= THREAD_TAG_MAX_LENGTH ? launcher.id : null; | |||
| } | |||
|
|
|||
| /** The bot a thread launched by `launchedBy` will work for, before that thread exists. */ | |||
| export const forkBotIdFor = Effect.fn("ThreadLaunchService.forkBotIdFor")( | |||
There was a problem hiding this comment.
This repeats linkForkBotWork's forkBotActingShell → launcherBotId walk, and both launch paths now run both. Resolve once and make linkForkBotWork take the resolved botId. Its return value is already ignored at both call sites.
There was a problem hiding this comment.
Fixed in a8ed701. The bot is resolved once with forkBotIdFor. linkForkBotWork now takes that id, dispatches the tag and returns void.
| @@ -1170,6 +1480,43 @@ const make = Effect.gen(function* () { | |||
| }, | |||
| ); | |||
| /* fork:end server-local-thread-branch */ | |||
| /* fork:begin fork-bot-crew-rules — see .fork/customizations.yaml#fork-bot-crew-rules | |||
| The claim carries the first message, so its bot is resolved before the thread exists. */ | |||
| const forkCrewBotId = | |||
There was a problem hiding this comment.
launchedBy !== undefined && reuseExistingThread !== true is checked here and again at the linkForkBotWork call below (line 1578). With one forkBotId resolved up front, both fenced blocks just read it, and the second bot lookup goes away.
There was a problem hiding this comment.
Fixed in a8ed701. The condition is checked once, the result goes into forkBotId, and both fenced blocks read it.
| : follower.follow({ cwd, threadId: input.threadId, runId: input.runId, local }), | ||
| ), | ||
| ); | ||
| if (yield* follower.canFollow(input.threadId)) yield* refresh; |
There was a problem hiding this comment.
This branch makes shared-checkout threads wait on the whole observer.refresh: the workspace rescan, identity probing, and the PR lookup it starts. But follow only needs the local status. Wait only on status + follow and leave the rescan on refreshes. Then upstream's "next turn must not wait for the display refresh" holds for these threads too.
There was a problem hiding this comment.
Fixed in a8ed701. The observer now starts workspaceEntries.refresh on its own fiber, so the inline path waits only on the status read and the follow. The new test, "returns the post-turn status without waiting for the workspace rescan", fails on the old code.
| @@ -119,6 +121,15 @@ export const layer = Layer.effect( | |||
| Effect.gen(function* () { | |||
| const threads = yield* ThreadManagement.ThreadManagementService; | |||
| return LocalCheckoutBranchFollower.of({ | |||
| canFollow: Effect.fn("LocalCheckoutBranchFollower.canFollow")( | |||
There was a problem hiding this comment.
This is a second copy of part of followLocalCheckoutBranch's guard (worktreePath === null && branch !== null), with its own shell read. Pull it into one isSharedCheckoutThread(shell) used by both, so the two can't drift apart.
There was a problem hiding this comment.
Fixed in a8ed701. One isSharedCheckoutThread rule now backs both the follow guard and canFollow.
| <> | ||
| {/* A plain folder has no branch picker to carry the workspace modes, so upstream's | ||
| selector offers them. */} | ||
| <BranchToolbarEnvModeSelector |
There was a problem hiding this comment.
This pastes upstream's selector into the fork-composer-shell fence, and the same eight props go to ComposerWorkspaceFooter again below. Upstream already renders this selector under showGitControls. Fence only that condition (&& !showBranchControls) and shrink the fence to the branch-selector arm. Then the next upstream change here doesn't conflict.
There was a problem hiding this comment.
Declining. The fork's fence also drops upstream's responsive wrapper (the hidden @xl:flex div, its separator, and the env-mode selector at wide widths), and that's what keeps the chips in one row. Bringing back upstream's render and fencing only the condition would bring the wrapper back and change the composer layout, which a sync shouldn't do. The eight repeated props are a small cost next to that.
NoahHendrickson
left a comment
There was a problem hiding this comment.
Code review of 8e8075d344
This diff has 5,331 files, more than anyone can read line by line, so the review covered the parts written by hand: the conflict resolutions in 2cb821e2aa and 8e8075d344 (read with git show --remerge-diff) and the follow-up commits 72e6110c34 and b8bdf3421b. Upstream code that merged without conflicts was not reviewed. Each finding below was checked against the source. The findings are in the body because GitHub can't attach inline comments to most files in a diff this large.
1. Bug: the Scheduled editor locks the model picker for GitHub PR tasks
apps/web/src/custom/scheduled/ScheduledTaskEditor.tsx:249 (from b8bdf3421b)
disabled={props.disabled || draft.threadId !== ""} locks the picker for a GitHub PR automation that the server is about to unbind from its thread. For GitHub tasks, ScheduledTaskService.upsert sets threadMode to new_thread and stores a null threadId (ScheduledTaskService.ts:1658 and :1667). Every PR delivery then starts a new thread that runs on the task's own model. ScheduledTaskDetail.tsx:591 already allows for this with draft.threadId && !draft.githubPrOpened. Switching the trigger to GitHub PR doesn't clear draft.threadId.
To reproduce: open a thread-bound automation and switch its trigger to "GitHub PR opened". The model picker stays disabled, so the user can't choose the model the PR threads will run on.
Fix: disabled={props.disabled || (draft.threadId !== "" && !draft.githubPrOpened)}
2. Nit: the queued Send tooltip gives the wrong reason for /clear messages
apps/web/src/custom/ForkQueuedRunsBanner.tsx:622
canSendRun(item.freshContext) can now be false while a run is active. That happens for a message armed by /clear, which can't be steered into the running turn unless the workflow is skipping compaction. The tooltip still says "There is no active run to steer", but a turn is visibly running.
Fix: give the fresh-context case its own reason, or hide the button as upstream's QueuedRunsControl does.
3. Nit: two pieces of the composer usage tray are still untranslated
apps/web/src/custom/ComposerUsageLimitsReadout.tsx:143 and :200
This PR moves formatResetsIn to the translated helper, but cursorUsageWindowDetails and collectExternalUsageLinks still come from the untranslated @t3tools/shared/usageLimits. UsageLimitsPooled now gets both from usageLimitsCopy with m. With a non-English UI language, the tray shows the external-link labels and the Cursor window labels in English, while the Usage page translates them.
Fix: import both from @t3tools/shared/usageLimitsCopy and pass m.
4. Suggestion: a cheap fix for the "waits for the workspace rescan" follow-up
apps/server/src/orchestration-v2/RunFinalizationService.ts:131
This is not a regression: custom already ran the refresh inline for every thread, and the PR body lists it as a follow-up. canFollow is true for every non-worktree thread that has a branch, so most local threads still run the whole observer.refresh inline: the workspaceEntries.refresh(cwd) file-index rescan, refreshLocalStatus and the shell read. That happens even when the branch hasn't changed, and the comment above ("the thread's next turn must not wait for it") no longer holds on this path. The follow only needs the status result. Running workspaceEntries.refresh(cwd) in refreshes and awaiting only the status read and the follow would fix most of that follow-up.
🤖 Reviewed by Claude Opus 5.5 (claude-opus-5-5) via Claude Code /code-review
Thread transfer impact✅ Thread transfer remains within every enforced ceiling.
Other scenarios4 of 64 scenario measurements changed or failed.
All 64 scenario measurements
Baseline: Scenario and decoded snapshot size10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.
Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed. |
Ports upstream pingdotgg#29846 to the fork's draft project chip, which builds its own project list: a manual sidebar order now orders the menu too. Upstream's two new tests pin upstream DOM and its 640px chat reserve, so their fork-specific lines are fenced and watched. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Shared-checkout threads wait on the status read only at finalize; the workspace rescan runs on its own fiber. One isSharedCheckoutThread rule backs both the follow and canFollow. - A launch resolves its bot once; linkForkBotWork takes that id. - The queued-runs banner reads the quiet projection and passes messages, as upstream's control does, and hides send for a /clear message that cannot steer the running turn. - The Scheduled editor no longer locks the model for GitHub PR tasks. - The composer usage tray translates Cursor window and external link labels; bot working checks the thread status, not its text. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Replies to the review findings that are only in the review bodies; the inline comments each have their own reply. The fixes are in a8ed701 and 537b862. Fixed
Not in this PR
|
…406 Resolves the 17 files where the sync changed upstream mobile code that the no3y redesign fences, and ports the redesign to what upstream moved: - The composer editor and surface now live in ComposerSurface.tsx; the no3y card's full-width editor and glass surface hunks moved with them. Upstream's compact-before-send control stays off the card, which keeps its own "Resume with less context" banner. - Upstream moved working, compacting, background work and snooze/settle out of its floating status into the feed, and syncing into the header. The no3y pill keeps them: fork/no3yPillStatus.ts rebuilds the pill's status in its old order from what upstream still computes, and the feed's closing status lines are hidden on iPhone so nothing shows twice. - Follows upstream renames (THREAD_LIST_ROW_LAYOUT, usageLimitsCopy helpers, subagentThreadTarget's reach, describeSchedule's translator). - Fork copy inside upstream files carries the fork-i18n-catalog disable. - Upstream's new SettingsScheduledTasksRouteScreen test stubs the fork's Automations screens, which it does not cover. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Brings
customup to upstreammainat ad2bdc7 (2,023 upstream commits), keeping every fork customization. The biggest upstream change is the gt-react i18n wave; the rest is server V2 follow-ups, desktop and the context menu, and ChatComposer/ChatView refactors.How the fork was kept
Translations. Upstream now translates all copy and lints for untranslated strings. Fork copy stays English for now:
i18n:checktolerates web keys the fork removed (fencedfork-i18n-catalog, with a guard).no-untranslated-copydisable.Translating fork copy into every locale is a separate decision.
Server.
thread.createnow carries the first message, so the fork resolves a launcher's bot before creation and applies crew rules to that message.canFollow), so the next queued turn can't beat the fork's branch follow. A new TestClock test covers this and fails without the fix.Web.
Desktop. The fork-identity fence moved to
DesktopSshEnvironment. The fork's copy of the context menu was swapped for upstream's new one.Declined upstream tests. Two upstream tests check UI the fork's sidebar cards don't have, the linked-issue badge and the keyboard sidebar tree. Each carries a note saying why.
Merged
customback in at 84afbb4. One conflict: the branch-link copy now sits next to upstream's translated "Copy branch name".Review
A 3-round Sol loop fixed:
Gemini 4 Neon found upstream fixes that never reached the fork's own components, and those are fixed:
/clearcould be steered into the running turn, and failed sends were silentPR review fixes: the bot is resolved once per launch; shared-checkout threads no longer wait for the workspace rescan; the queue banner uses the quiet projection and translated labels; the Scheduled editor no longer locks the model for GitHub PR tasks; and the usage tray's labels are translated. The fork's draft project picker also follows the manual sidebar order now (upstream fix(web): the new-thread project picker follows the manual project order pingdotgg/t3code#29846).
Checks run locally
i18n:check, fmt, knip.src/custom, plus the touched browser suites.Follow-ups (not in this PR)
QueuedRunsControl, so the fork banner stops drifting.🤖 Signed: Claude Opus 5.5 (
claude-opus-5-5) via Claude Codegpt-6.2-sol) via Codex: review (fixes applied)gemini-4-neon) via Antigravity: review (fixes applied)Reviewed with sol-loop: 3 rounds with gpt-6.2-sol. Sol verdict: approved