Skip to content

fix(gemini): trust workspace for headless gemini-cli (exit 55) - #151

Merged
charlesgreen merged 2 commits into
mainfrom
fix/gemini-cli-trust-workspace
Sep 19, 2026
Merged

charlesgreen merged 2 commits into
mainfrom
fix/gemini-cli-trust-workspace

Conversation

@charlesgreen

Copy link
Copy Markdown
Contributor

Summary

@google/gemini-cli@0.60.0 defaults folder trust on. Headless Aixgo runs in a fresh Actions checkout hit FatalUntrustedWorkspaceError → exit 55. -y does not bypass trust.

  • Set GEMINI_CLI_TRUST_WORKSPACE=true unless ExtraEnv already sets it
  • Include CLI output tail in the engine error (so bot comments are actionable)

Evidence

Test plan

gemini-cli 0.60+ exits 55 (FatalUntrustedWorkspaceError) when folder
trust is on and the Actions checkout is not in trustedFolders.json.
-y auto-approves tools but does not bypass that gate.

Set GEMINI_CLI_TRUST_WORKSPACE=true by default (ExtraEnv can override)
and include a short CLI output tail in engine errors so bot comments
show the real failure next time.

Unblocks Sync #1/#2 and code#147 dogfood after Vertex preflight.
@codecov

codecov Bot commented Sep 19, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

Codecov patch flagged the empty-output branch of the exit-55
error formatting. Exercise a non-zero exit with no stdout/stderr.
@charlesgreen
charlesgreen merged commit 5c85111 into main Sep 19, 2026
3 checks passed
@charlesgreen
charlesgreen deleted the fix/gemini-cli-trust-workspace branch September 19, 2026 11:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant