Fix Codex engine auth wiring for gateway session keys and add harness diagnostics#34470
Fix Codex engine auth wiring for gateway session keys and add harness diagnostics#34470Copilot wants to merge 4 commits into
Conversation
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
|
@copilot merge main and recompute |
|
@copilot the key is still passed through OPENAI_API_KEY but this is a session key, not the actual OpenAI key. |
…ntic-engine-auth # Conflicts: # .github/workflows/daily-cache-strategy-analyzer.lock.yml # .github/workflows/daily-fact.lock.yml # .github/workflows/daily-observability-report.lock.yml # .github/workflows/dev.lock.yml # .github/workflows/duplicate-code-detector.lock.yml # .github/workflows/grumpy-reviewer.lock.yml # .github/workflows/issue-arborist.lock.yml # .github/workflows/necromancer.lock.yml # .github/workflows/schema-feature-coverage.lock.yml # .github/workflows/smoke-call-workflow.lock.yml # .github/workflows/smoke-codex.lock.yml Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Done. I merged |
|
🚀 Smoke Gemini MISSION COMPLETE! Gemini has spoken. ✨ Caution agentic threat detected |
|
🌑 The shadows whisper... Smoke Codex failed. The oracle requires further meditation... |
|
🚀 Smoke Pi MISSION COMPLETE! Pi delivered. 🥧 |
|
🎬 THE END — Smoke Claude MISSION: ACCOMPLISHED! The hero saves the day! ✨ |
|
📰 BREAKING: Smoke Copilot is now investigating this pull request. Sources say the story is developing... |
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Fixed in |
Agent Container Tool Check
Result: 11/12 tools available Status: FAIL —
|
|
Caution agentic threat detected Smoke Test Results\n1. GitHub MCP Testing: ✅\n2. Web Fetch Testing: ✅\n3. File Writing Testing: ✅\n4. Bash Tool Testing: ✅\n5. Build gh-aw: ❌\n\nOverall status: FAILWarning Firewall blocked 1 domainThe following domain was blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "localhost"See Network Configuration for more information.
|
|
🤖 Beep boop! The smoke test agent was here! Ran all systems checks and everything looks 💚. Don't mind me, just a robot making sure the lights are on. 🔦✨ Warning Firewall blocked 6 domainsThe following domains were blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "accounts.google.com"
- "android.clients.google.com"
- "clients2.google.com"
- "contentautofill.googleapis.com"
- "safebrowsingohttpgateway.googleapis.com"
- "www.google.com"See Network Configuration for more information.
|
|
✅ Smoke test PASS — Run 26365438030 All 16 tests passed.
Overall: PASS Warning Firewall blocked 6 domainsThe following domains were blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "accounts.google.com"
- "android.clients.google.com"
- "clients2.google.com"
- "contentautofill.googleapis.com"
- "safebrowsingohttpgateway.googleapis.com"
- "www.google.com"See Network Configuration for more information.
|
Comment MemoryNote This comment is managed by comment memory.It stores persistent context for this thread in the code block at the top of this comment. Warning Firewall blocked 6 domainsThe following domains were blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "accounts.google.com"
- "android.clients.google.com"
- "clients2.google.com"
- "contentautofill.googleapis.com"
- "safebrowsingohttpgateway.googleapis.com"
- "www.google.com"See Network Configuration for more information.
|
|
📰 DEVELOPING STORY: Smoke Copilot reports failed to deliver outputs. Our correspondents are investigating the incident... |
🧪 Smoke Test: Claude — Run §26365437982Core tests (#1–13): ✅ all green (Serena #3 Overall status: PARTIAL Warning Firewall blocked 6 domainsThe following domains were blocked by the firewall during workflow execution:
network:
allowed:
- defaults
- "accounts.google.com"
- "android.clients.google.com"
- "clients2.google.com"
- "contentautofill.googleapis.com"
- "safebrowsingohttpgateway.googleapis.com"
- "www.google.com"See Network Configuration for more information.
|
There was a problem hiding this comment.
💥 Automated smoke test review - all systems nominal!
Warning
Firewall blocked 6 domains
The following domains were blocked by the firewall during workflow execution:
accounts.google.comandroid.clients.google.comclients2.google.comcontentautofill.googleapis.comsafebrowsingohttpgateway.googleapis.comwww.google.com
To allow these domains, add them to the
network.allowedlist in your workflow frontmatter:
network:
allowed:
- defaults
- "accounts.google.com"
- "android.clients.google.com"
- "clients2.google.com"
- "contentautofill.googleapis.com"
- "safebrowsingohttpgateway.googleapis.com"
- "www.google.com"See Network Configuration for more information.
💥 [THE END] — Illustrated by Smoke Claude · opus47 9.3M
| yaml.WriteString(indent + "name = \"" + codexOpenAIProxyProviderName + "\"\n") | ||
| yaml.WriteString(indent + "base_url = \"" + e.getOpenAIProxyProviderBaseURL() + "\"\n") | ||
| yaml.WriteString(indent + "env_key = \"OPENAI_API_KEY\"\n") | ||
| yaml.WriteString(indent + "env_key = \"CODEX_API_KEY\"\n") |
There was a problem hiding this comment.
🤖 Smoke test review — switching env_key to CODEX_API_KEY aligns the proxy provider with the canonical session-key naming used elsewhere in the engine. Worth a quick mention in the PR body that any downstream consumers exporting OPENAI_API_KEY directly will need to set CODEX_API_KEY instead.
| envVars["CODEX_API_KEY"] = true | ||
| envVars["OPENAI_API_KEY"] = true // Fallback for CODEX_API_KEY | ||
|
|
||
| // Check each MCP tool for required environment variables |
There was a problem hiding this comment.
🤖 Smoke test review — keeping OPENAI_API_KEY exposed as a fallback in the shell environment policy is a sensible compatibility shim, but consider gating it behind a feature flag or adding a brief comment indicating when this fallback will be removed.
Codex workflow runs were failing because the engine/harness path treated gateway-issued session keys like provider API keys. This change aligns the Codex auth contract end-to-end (engine → generated config → harness) and adds targeted logging to make auth misconfiguration immediately obvious.
Auth contract fix (Codex engine, Go)
Harness auth handling + diagnostics (
codex_harness.cjs)Generated lock/config alignment
Spec/flags parity checks
✨ PR Review Safe Output Test - Run 26365437982
Warning
Firewall blocked 6 domains
The following domains were blocked by the firewall during workflow execution:
accounts.google.comandroid.clients.google.comclients2.google.comcontentautofill.googleapis.comsafebrowsingohttpgateway.googleapis.comwww.google.comSee Network Configuration for more information.