Repository navigation
fix(cli): persist a deploy's env credential so a new host-agent resumes it - #1024
Merged
Merged
Conversation
…es it An api_key credential (ANTHROPIC/GEMINI/CURSOR_API_KEY) lived only in the supervisor's memory. A Box rebuilt on its volume, a wake or a self-update restart resumed the session with no key: live on the dev release gate, "ACP start failed for antigravity: Authentication required". It is now persisted 0600 per deploy (~/.codeam/credential-env/<deployId>.json, like the house-proxy config) and re-injected on resume; refresh/cleanup keep it in step. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Found by the codeam-cli v2.76.46 release gate (dev): after the Box was rebuilt on its volume, the host-agent resumed an Antigravity session (api_key) and it failed at start —
ACP start failed for antigravity: Authentication required.credentialEnvByDeploywas in memory only, so ANY env-delivered key (Claude/Gemini/Cursor/Antigravity api keys) was lost on a Box rebuild, a wake or a self-update restart; login-file credentials (Claude/Codex OAuth) were unaffected (on the volume).Fix: persist the env per deploy, 0600, atomically (
~/.codeam/credential-env/<deployId>.json, same stance as the house-proxy config and the OAuth files), re-inject on resume when memory is empty, keep it in step on re-link and remove it on workspace cleanup.Test:
host-agent.test.ts— a NEW supervisor resumes the session with the key (fails without the fix); whole host-agent suite 188/188.🤖 Generated with Claude Code
Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.