Skip to content

Point Codex's gobstopper provider away from the proxy on gobstopper off - #281

Merged
0thernet merged 2 commits into
mainfrom
gobstopper-off-pinned-threads
Oct 16, 2026
Merged

0thernet merged 2 commits into
mainfrom
gobstopper-off-pinned-threads

Conversation

@0thernet

Copy link
Copy Markdown
Member

Problem

Codex records the provider each session started with and keeps it when a session is resumed. gobstopper off (#280) only commented out the default model_provider = "gobstopper", so resumed sessions still called http://127.0.0.1:<port>/backend-api/codex after the proxy stopped and failed with Connection failed: error sending request. This happened on a real machine: about 114 sessions were pinned to the provider.

Change

  • off also rewrites the loopback base_url in [model_providers.gobstopper] to where the proxy sent requests: https://chatgpt.com for /backend-api/... and https://api.openai.com for /v1. If the service set --chatgpt-upstream or --openai-upstream, it uses those instead. The rewritten line is marked # turned off by \gobstopper off`; was ` and keeps its indentation.
  • on restores marked lines to http://127.0.0.1:<current port><path>, including when another provider is the default. With no service and no saved state, it takes the port from the marker.
  • off reports only what changed: new sessions, resumed sessions, or both. It still warns when a loopback URL is left, such as an unmapped path.
  • Updated docs/proxy.md and the CHANGELOG.

Checks

  • New unit tests cover pinned sessions, custom upstreams, restore under another default provider, and the warning.
  • fmt and clippy (-D warnings) pass. Workspace tests pass except three timing tests (apple::… ×2 and clef_decide_timeout…), which fail only under full parallel load and pass alone.
  • Smoke-tested off against a throwaway home directory.
  • An independent review found three issues: custom upstreams, restore under another provider, and contradictory messaging. All three are fixed.
  • Assurance receipts will be re-imported from this PR's CI run.

🤖 Generated with Claude Code

…off`

Codex resumes each session with the provider it started with, so commenting
out the default `model_provider` left resumed sessions calling the stopped
proxy ("Connection failed: error sending request"). `off` now rewrites the
gobstopper provider's loopback base_url to the proxy's upstream (official or
`--chatgpt-upstream`/`--openai-upstream`), marked so `on` can restore it on
the current port, including when another provider is the default.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@0thernet
0thernet enabled auto-merge (squash) October 16, 2026 23:15
@vercel

vercel Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
gobstopper Ready Ready Preview Oct 16, 2026 11:23pm UTC

Request Review

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@0thernet
0thernet merged commit 1aa7129 into main Oct 16, 2026
21 checks passed
@0thernet
0thernet deleted the gobstopper-off-pinned-threads branch October 16, 2026 23:29

This branch was successfully deployed

1 active deployment
Preview — c1875091 Deployed Oct 16, 2026 by vercel[bot]
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