decolua/9router · error · Error
No Google Cloud Project found. Please ensure you have a GCP
Error message
No Google Cloud Project found. Please ensure you have a GCP project with Gemini Code Assist enabled.
What it means
Thrown by AntigravityService.connect after a successful token exchange when loadCodeAssist returns no projectId, meaning no Google Cloud project associated with the account has Gemini Code Assist (Cloud AI Companion) enabled. The OAuth credentials are valid at this point; the account simply isn't provisioned for the service this flow onboards into.
Source
Thrown at src/lib/oauth/services/antigravity.js:297
}
spinner.start("Exchanging code for tokens...");
// Exchange code for tokens
const tokens = await this.exchangeCode(callbackParams.code, redirectUri);
spinner.text = "Fetching user info...";
// Get user info
const userInfo = await this.getUserInfo(tokens.access_token);
spinner.text = "Loading Code Assist configuration...";
// Load Code Assist to get project ID and tier
const { projectId, tierId } = await this.loadCodeAssist(tokens.access_token);
if (!projectId) {
throw new Error("No Google Cloud Project found. Please ensure you have a GCP project with Gemini Code Assist enabled.");
}
spinner.text = "Onboarding to Gemini Code Assist...";
// Complete onboarding to enable Gemini Code Assist
const onboardResult = await this.completeOnboarding(tokens.access_token, projectId, tierId);
const finalProjectId = onboardResult.projectId || projectId;
spinner.text = "Saving tokens to server...";
// Save tokens to server
await this.saveTokens(tokens, userInfo, finalProjectId);
spinner.succeed(`Antigravity connected successfully! (${userInfo.email}, Project: ${finalProjectId})`);
return true;
} catch (error) {
spinner.fail(`Failed: ${error.message}`);
throw error;View on GitHub (pinned to 90b52e06ff)
Solutions
- Enable the Gemini Code Assist / Cloud AI Companion API on a GCP project at console.cloud.google.com, then reconnect
- Make sure you select the Google account that actually owns a Code Assist-enabled project during the consent screen
- Set up a project at console.cloud.google.com if you have none, enable Code Assist, and re-run connect
- Check Workspace admin policies if using an organization account — Code Assist may need admin opt-in
Defensive patterns
Strategy: validation
Validate before calling
const { projectId, tierId, raw } = await service.loadCodeAssist(tokens.access_token);
if (!projectId) {
console.error(`No Code Assist project. loadCodeAssist raw keys: ${Object.keys(raw).join(',')}. Enable Gemini Code Assist on a GCP project first.`);
process.exit(1);
} Type guard
function isCodeAssistReady(load) { return load != null && (typeof load.projectId === 'string' && load.projectId.length > 0); } Try / catch
try {
await service.connect();
} catch (e) {
if (e.message.includes('No Google Cloud Project found')) {
console.error('Enable Gemini Code Assist on a GCP project, then re-run connect with the correct Google account.');
} else throw e;
} Prevention
- Enable Gemini Code Assist on a GCP project before running connect
- Select the Google account that owns the Code Assist project on the consent screen
- For Workspace accounts, have the admin enable Code Assist first
- Verify project setup at console.cloud.google.com before troubleshooting the CLI
When it happens
Trigger: loadCodeAssist responds 200 with no cloudaicompanionProject for the freshly exchanged access_token — the Google account has zero Code Assist-enabled GCP projects.
Common situations: Brand-new personal Google account never used with Gemini Code Assist; GCP project created but the Gemini Code Assist API never enabled; Workspace account where Code Assist is disabled by policy; wrong Google account chosen on the consent screen.
Related errors
- Vertex: failed to mint access token from Service Account JSO
- Vertex: failed to refresh access token from ADC JSON (author
- loadCodeAssist failed: HTTP ${response.status} ${errorText.s
- onboardUser HTTP ${response.status}: ${errorText.slice(0, 20
- No Zed organization selected
AI-assisted analysis of decolua/9router@90b52e06ff (2026-08-30).
Data as JSON: /api/errors/7a4ec68e6b98a94e.
Report an issue: GitHub.