GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — feat(server): stop Codex and Cursor threads at subscription limits by adampeterhiggins · Pull Request #400 · adampeterhiggins/t3code

Conversation

@adampeterhiggins

@adampeterhiggins adampeterhiggins commented Oct 21, 2026

Copy link
Copy Markdown
Owner

Stop at subscription limit only protected Claude. A long unattended Codex thread could keep going on credits, and a Cursor thread on on-demand usage, once the subscription allowance ran out.

Codex and Cursor now offer the same thread option and follow the application-wide setting:

  • Before a guarded turn the adapter reads fresh usage. It refuses the prompt if an allowance is used up or usage can't be read. The run fails as a usage limit, so the usual Limited recovery and resume-at-reset apply.
  • Codex during a turn: the guard interrupts the turn when Codex's own rate-limit updates show an allowance at 100%, or when the guard is switched on mid-turn. The turn then fails with that limit.
  • Cursor during a turn: Cursor sends no usage while it runs, so a guarded run rechecks once a minute, and immediately when the guard is switched on. It is cancelled once either the Auto or the API pool is used up.
  • During a turn, a failed usage read leaves the work running (it already passed the check before it started). Only an actual exhausted reading stops it.

The exhaustion check, thread/app precedence and option descriptor now live in provider-core (SubscriptionLimitPolicy). Claude uses the same check, and its behaviour is unchanged. Turn-start failures that carry the guard's stop keep its usage-limit failure instead of becoming a generic provider error. stopAtSubscriptionLimit is filtered out of the parameters sent to Cursor's SDK.

Settings copy on web and mobile, the user guide (docs/user/usage.md#stop-at-subscription-limits) and docs/fork-differences.md are updated.

Test plan

  • Codex adapter replay tests: a guarded turn is refused before turn/start, and a running one is interrupted and fails as subscription_limit_guard with the reset time.
  • Cursor adapter tests: a guarded turn is refused before sending, a running one is cancelled on recheck, and the option never reaches SDK params.
  • Shared policy unit tests and a run-execution test that the start refusal persists as a usage limit.
  • Existing Claude, Codex, run-start and Codex driver/catalog suites pass; server, provider-core and provider-cursor typecheck.
  • Not exercised in a running client or against a real exhausted account.

Model: Claude Opus 5.5. Harness: Claude Code in T3 Code.

🤖 Generated with Claude Code

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@adampeterhiggins @claude
feat(server): stop Codex and Cursor threads at subscription limits
6ec6a58
Stop at subscription limit only protected Claude, so Codex could keep going on credits and Cursor on on-demand usage. Codex and Cursor now offer the same thread option and follow the application setting: a guarded turn is refused when the allowance is used up, and a running one stops when Codex reports it or a one-minute Cursor recheck finds it.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@adampeterhiggins
adampeterhiggins merged commit a14388d into main Oct 21, 2026
@adampeterhiggins
adampeterhiggins deleted the ah/subscription-limit-guard-codex-cursor branch October 21, 2026 07:15
@adampeterhiggins adampeterhiggins mentioned this pull request Oct 27, 2026
merge upstream/main into fork #502
Merged
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@adampeterhiggins
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.