feat(proactive-agents): pear-side proactive-agent feature (manager + UI files)#10
Conversation
|
Warning Rate limit exceeded
You’ve run out of usage credits. Purchase more in the billing tab. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Free Run ID: 📒 Files selected for processing (7)
Note 🎁 Summarized by CodeRabbit FreeYour organization is on the Free plan. CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please upgrade your subscription to CodeRabbit Pro by visiting https://app.coderabbit.ai/login. Comment |
| export function mapDeployStatus(result: DeployResultWithHostedStatus): ProactiveAgentDeployStatus { | ||
| const handleStatus = result.runHandle?.status | ||
| if (handleStatus === 'starting' || handleStatus === 'warming') return 'warming' | ||
| if (handleStatus === 'failed' || handleStatus === 'error') return 'error' | ||
| if (handleStatus === 'active') return 'active' | ||
|
|
||
| if (result.status === 'warming' || result.status === 'error') return result.status | ||
| return 'active' | ||
| } |
There was a problem hiding this comment.
🔴 mapDeployStatus maps cancelled run handle status to active instead of error
The CloudRunHandleStatus type explicitly includes 'cancelled' (proactive-agent.bundle.ts:84), but mapDeployStatus has no branch handling it. When handleStatus === 'cancelled', none of the three status checks match, so execution falls through to the default return 'active' at line 201. This means a cancelled deployment is reported as successfully active. The deployResultError function (proactive-agent.bundle.ts:204-211) independently may or may not find an error message, leading to either a silent false success or a contradictory { status: 'active', error: '...' } result returned to the caller at proactive-agent.ts:272-281.
| export function mapDeployStatus(result: DeployResultWithHostedStatus): ProactiveAgentDeployStatus { | |
| const handleStatus = result.runHandle?.status | |
| if (handleStatus === 'starting' || handleStatus === 'warming') return 'warming' | |
| if (handleStatus === 'failed' || handleStatus === 'error') return 'error' | |
| if (handleStatus === 'active') return 'active' | |
| if (result.status === 'warming' || result.status === 'error') return result.status | |
| return 'active' | |
| } | |
| export function mapDeployStatus(result: DeployResultWithHostedStatus): ProactiveAgentDeployStatus { | |
| const handleStatus = result.runHandle?.status | |
| if (handleStatus === 'starting' || handleStatus === 'warming') return 'warming' | |
| if (handleStatus === 'failed' || handleStatus === 'cancelled' || handleStatus === 'error') return 'error' | |
| if (handleStatus === 'active') return 'active' | |
| if (result.status === 'warming' || result.status === 'error') return result.status | |
| return 'active' | |
| } |
Was this helpful? React with 👍 or 👎 to provide feedback.
…UI files) Spec 03 main-process + renderer scaffolding: - src/main/proactive-agent.ts + .bundle.ts + .types.ts: ProactiveAgentManager (list/create/update/deploy/pause/resume/undeploy + run-transcript), bundle stager for handler source, route through resolveCloudAuth. - components/proactive/: ProactiveAgentsSection, ProactiveAgentCard, ProactiveAgentEditor. - hooks/use-proactive-agent.ts. Builds on shared scaffolding (#7). NOTE: the UI is not wired yet — ProactiveAgentsSection is defined but never rendered, the AppTabKind union does not include 'proactive-agent-editor', App.tsx does not render the editor, and @monaco-editor/react is not in package.json. Those gaps, plus vendored runtime types and the cloud proactive-personas backend (routes/schema/runtime), are tracked in specs/03-proactive-agents.md. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
CloudRunHandleStatus includes 'cancelled' but mapDeployStatus had no branch
for it, so a cancelled deployment fell through to the default 'active' and
was reported as a successful one (or produced a contradictory
{ status: 'active', error: '…' } pair).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
0013d77 to
b71c8c1
Compare
Fix #11: WebGL doesn't repaint while the host is display:none. When the visible effect runs after a hidden→visible transition, call the new runtime.refreshOnShow() so the canvas redraws. Fix #10: the runtime captures opts.getInputSrtt once at first acquire. Rebind on each effect run via setInputSrttGetter so a remount with a fresh inputSrttRef can't leave the predictor reading a stale ref. Fix #14 (detach guard) was implemented inside the runtime in the prior commit by tracking lastMountedContainer — no use-terminal change needed.
Spec 03 main-process + renderer scaffolding. Builds on #7 (shared scaffold).
proactive-agent.ts+.bundle.ts+.types.ts:ProactiveAgentManager(list/create/update/deploy/pause/resume/undeploy + run-transcript), bundle stager, routes throughresolveCloudAuth.components/proactive/:ProactiveAgentsSection,ProactiveAgentCard,ProactiveAgentEditor.hooks/use-proactive-agent.ts.Known gap (UI is not wired yet):
ProactiveAgentsSectionis defined but never rendered;AppTabKinddoes not include'proactive-agent-editor';App.tsxdoes not render the editor;@monaco-editor/reactis not inpackage.json. These + vendored runtime types + the cloudproactive-personasbackend are tracked in slim specspecs/03-proactive-agents.mdfrom #5.🤖 Generated with Claude Code