fix(status): wait for inference after gateway recovery - #8572
Conversation
Signed-off-by: Julie Yaunches <jyaunches@nvidia.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughSandbox status checks track successful managed-gateway recovery and retry the inference route up to three times with two-second delays. Tests cover successful recovery, repeated probe failure, ordinary status lookup, and an increased policy-transition setup timeout. ChangesInference recovery probing
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested labels: Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
Code Coverage OverviewLanguages: TypeScript TypeScript / code-coverage/pluginThe overall coverage in commit 43a1234 in the TypeScript / code-coverage/cliThe overall coverage in commit 43a1234 in the Show a code coverage summary of the most impacted files.
Updated |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
src/lib/actions/sandbox/status-snapshot.ts (1)
571-578: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winExtract the recovery probe loop into a private helper.
collectSandboxStatusSnapshotalready owns several lifecycle paths. Move this retry loop to a focused helper that acceptssandboxName,recoveredManagedGateway,probe, anddelay. Keep the action as the workflow owner.As per coding guidelines, “Keep function complexity low.”
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src/lib/actions/sandbox/status-snapshot.ts` around lines 571 - 578, Extract the retry loop from collectSandboxStatusSnapshot into a private helper that accepts sandboxName, recoveredManagedGateway, probe, and delay, and returns the resulting gatewayChain. Replace the inline loop with a call to this helper while keeping collectSandboxStatusSnapshot responsible for the surrounding workflow and preserving the existing retry counts and delay behavior.Source: Coding guidelines
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@src/lib/actions/sandbox/status-snapshot.ts`:
- Around line 571-578: Extract the retry loop from collectSandboxStatusSnapshot
into a private helper that accepts sandboxName, recoveredManagedGateway, probe,
and delay, and returns the resulting gatewayChain. Replace the inline loop with
a call to this helper while keeping collectSandboxStatusSnapshot responsible for
the surrounding workflow and preserving the existing retry counts and delay
behavior.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: 63a3c6b7-59b9-4e76-b72a-70a8e5470db9
📒 Files selected for processing (2)
src/lib/actions/sandbox/status-snapshot-inference-health.test.tssrc/lib/actions/sandbox/status-snapshot.ts
PR Review Advisor — No blocking findings reportedAdvisor assessment: No blocking advisor findings reported Model lanes
Second-opinion terminology and E2E selections are advisory. Live E2E does not run automatically for pull requests. 1 semantic terminology decisionTerminology decisions are advisory. They affect the assessment only when a separate finding identifies concrete semantic impact.
E2E guidanceAdvisory only. A maintainer can dispatch the default E2E suite against this exact revision. Recommended E2E: This automated review informs maintainers. Warnings and suggestions do not require a response. A maintainer decides whether to merge. |
Signed-off-by: Julie Yaunches <jyaunches@nvidia.com>
Summary
Sandbox status now waits for the authoritative inference route to converge after it automatically recovers a stopped agent gateway. Ordinary status checks remain single-probe, and persistent recovery failures still fail closed.
Changes
inference.localup to three times, with two-second delays, only after that recovery.Type of Change
Quality Gates
Documentation Writer Review
no-docs-neededdocs/reference/commands.mdxalready states that status restores the gateway and host forwards before probing inference.DGX Station Hardware Evidence
Verification
Signed-off-by:line and every commit appears asVerifiedin GitHubpre-commit,commit-msg, andpre-pushhooks passed, ornpm run validate:prpassed after refreshingorigin/mainwhen hooks were skipped or unavailablenpm testfor broad runtime/test-harness changes;npm run checkfor repo-wide validation/coverage changes — command/result:npm run docsbuilds without warnings (doc changes only)Signed-off-by: Julie Yaunches jyaunches@nvidia.com
Summary by CodeRabbit