{"record":{"id":"7d8a7683723aab0b","repo":"Hmbown/CodeWhale","slug":"codewhale-config-legacy-antigravity-tombstone-message","errorCode":null,"errorMessage":"codewhale_config::LEGACY_ANTIGRAVITY_TOMBSTONE_MESSAGE","messagePattern":"codewhale_config::LEGACY_ANTIGRAVITY_TOMBSTONE_MESSAGE","errorType":"error_code","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/tui/src/config.rs","lineNumber":12656,"sourceCode":"        path.to_path_buf(),\n    )\n    .read_grant(consent_provider, source, path)?;\n    match source {\n        codewhale_config::ExternalCredentialSource::CodexCli => {\n            crate::oauth::get_credentials(&grant).map(|_| ())\n        }\n        codewhale_config::ExternalCredentialSource::GrokCli => {\n            crate::oauth::validate_grok_external_credentials(&grant)\n        }\n        codewhale_config::ExternalCredentialSource::DshCli => {\n            crate::dsh_credentials::deepseek_api_key_from_grant(&grant)?\n                .map(|_| ())\n                .context(\"the DeepSeek Harness credentials file holds no DEEPSEEK_API_KEY\")\n        }\n        // Retired: the reader is gone, so a legacy consent record validates\n        // to nothing rather than resolving a route (PRD §4.4 PROD-002).\n        codewhale_config::ExternalCredentialSource::AgyCli => {\n            anyhow::bail!(codewhale_config::LEGACY_ANTIGRAVITY_TOMBSTONE_MESSAGE)\n        }\n        codewhale_config::ExternalCredentialSource::KimiCodeCli => anyhow::bail!(\n            \"Kimi CLI credentials are never imported; configure a Kimi API key instead\"\n        ),\n    }\n}\n\n/// Persist an explicitly confirmed read-only external credential grant and\n/// update the live mirror only after the comment-preserving disk mutation\n/// succeeds.\n///\n/// Order is load-bearing (#5772): the caller has already shown the\n/// confirmation disclosure, this function then reads and validates the exact\n/// consented file, and only a usable credential is allowed to produce a\n/// persisted consent record.\npub(crate) fn persist_external_credential_consent_for_at(\n    config_path: Option<&Path>,\n    live_config: &mut Config,","sourceCodeStart":12638,"sourceCodeEnd":12674,"githubUrl":"https://github.com/Hmbown/CodeWhale/blob/433685b2024e7bc4c99e1e2e326bcad39b4d9d65/crates/tui/src/config.rs#L12638-L12674","documentation":"The legacy Antigravity (AgyCli) external-credential reader has been retired: a legacy consent record deliberately validates to nothing and resolves no route. Any attempt to use it bails with a tombstone message defined in `codewhale_config::LEGACY_ANTIGRAVITY_TOMBSTONE_MESSAGE`.","triggerScenarios":"A stored external-credential record with `ExternalCredentialSource::AgyCli` reaching the credential resolution/validation path (e.g. leftover consent state from before the retirement).","commonSituations":"Upgrading from an older version that supported `agy` CLI consent import; stale credential files on disk referencing the retired source.","solutions":["Delete or migrate the stale external-credential record referencing AgyCli","Re-authenticate Antigravity access through a currently supported path if needed","Read the tombstone message text for the migration guidance it embeds"],"exampleFix":"// before\n{ \"source\": \"agy-cli\", ... }\n// after\nremove the record or re-grant via a supported ExternalCredentialSource","handlingStrategy":"validation","validationCode":"if source == ExternalCredentialSource::AgyCli {\n    eprintln!(\"Antigravity CLI import is retired; re-auth via a supported source\");\n    return;\n}","typeGuard":null,"tryCatchPattern":"match validate_external_credential(record) {\n    Err(e) if e.to_string().contains(\"Antigravity\") || e.to_string().contains(\"tombstone\") => {\n        eprintln!(\"legacy AgyCli consent record detected — remove or migrate it\");\n    }\n    r => r?,\n}","preventionTips":["Clean up pre-retirement external credential records after upgrading","Check release/migration notes before reusing exported credential state"],"tags":["migration","legacy","credentials"],"backgroundTag":"deprecated-api-usage","analyzedSha":"433685b2024e7bc4c99e1e2e326bcad39b4d9d65","analyzedAt":"2026-09-15T12:24:24.634Z","contentChangedAt":"2026-09-15T12:24:24.634Z","schemaVersion":2},"datasetVersion":"2026-09-22T16:17:23.217Z"}