Studio: keep the plan review mounted through approval

Keying PlanReview on planRevision remounted it mid-approve when updateResearchPlan bumped the revision, resetting the local pending flag and re-enabling Start research while the approve was still in flight, which allowed a duplicate approve. Key on runId only.
This commit is contained in:
danielhanchen 2026-07-19 09:18:03 +00:00
commit 5329ae6529

View file

@ -902,7 +902,10 @@ export function ResearchActivityPanel({
</div>
) : null}
</header>
<PlanReview key={`${runId}-${run.planRevision}`} runId={runId} />
{/* Key on runId only: keying on planRevision remounted PlanReview mid-approve
(updateResearchPlan bumps the revision), resetting local `pending` and
re-enabling "Start research" during the in-flight approve. */}
<PlanReview key={runId} runId={runId} />
<div
ref={viewportRef}
role="log"