Skip to content

fix(codex): make auto-review free from October 6 - #1354

Open
validatedev wants to merge 4 commits into
mainfrom
fix/codex-change-calculation-auto-review-free
Open

validatedev wants to merge 4 commits into
mainfrom
fix/codex-change-calculation-auto-review-free

Conversation

@validatedev

@validatedev validatedev commented Oct 6, 2026 •

Copy link
Copy Markdown
Collaborator

TL;DR

Treat Codex auto-review as free from October 6, 2026 at 00:00 UTC, while preserving earlier model-rate estimates and the codex-auto-review name and measured tokens. The policy follows the calendar date of Tibo’s announcement that auto-review is now free for users signed in through ChatGPT.

What was happening

  • OpenUsage priced auto-review through dated paid models, most recently GPT-5.6 Luna, including requests made after the free-pricing announcement.
  • A zero-cost model would normally be grouped under “Other” when paid models were present. Periods crossing the cutoff could also hide auto-review because its historical cost made the combined row positive but small.

What this changes

  • Apply a shared inclusive cutoff to timestamped native Codex, pi, and OpenCode requests. Earlier usage keeps the previous dated model estimates; free requests use $0 before catalog or optional paid-fallback lookup.
  • Require the request timestamp in shared Codex pricing and separate OpenCode’s prepared-rate cache by effective pricing model, so historical and free requests cannot reuse each other’s rates.
  • Handle older native cached mappings and carried pi estimates without charging for free requests. Earlier positive pi costs and ordinary model pricing retain their existing behavior.
  • Keep auto-review’s measured tokens in totals and trends and its model name in a separate breakdown row, including periods that combine earlier paid estimates with free requests. Ordinary Luna and Luna Reserve remain priced as before, and ordinary small models still fold into “Other”.
  • Update the documentation and add regression tests on both sides of the boundary, UTC offsets, cache order, service tiers, fallback handling, and a mixed Last 30 Days period where historical auto-review cost is below 5% of spend.

Heads-up

The announcement establishes a calendar date, without an exact activation instant or a retroactive waiver. OpenUsage uses the start of October 6 in UTC as its date boundary. Local history is recalculated using each request’s recorded timestamp; synced estimates from another Mac update when that source Mac refreshes in the updated app.

Tests

  • swift test: 1,568 passed, 3 gated live/parity tests skipped, 0 failures.
  • Focused auto-review pricing and spend-breakdown tests: 22 passed, 0 failures. The full suite includes the pi and OpenCode boundary regressions.
  • CONFIG=debug ./script/build_and_run.sh verify: rebuilt, restarted, and confirmed the app is running.
  • Astra independently reviewed the final changes and found no issues; it checked the completed local validation logs.
  • git diff --check passed.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Important

The zero-cost rule also rewrites usage from before the announced free-service change. Its historical scope needs to be corrected or supported by an explicit retroactive policy before merging.

Reviewed changes Reviewed the Codex pricing rule, parser/cache changes, model-breakdown behavior, regression tests, documentation, and screenshot.

  • Known Free Pricing: Recognizes codex-auto-review as $0 before catalog lookup or paid fallbacks, including cached events with the former Luna mapping.
  • Parsing And Cache: Removes the dated auto-review fallback and invalidates persisted parsed events while retaining Luna Reserve pricing.
  • Breakdown Visibility: Keeps free auto-review tokens in totals and a separate named row alongside paid models.
  • Regression Coverage: Adds exact assertions for fallback handling, cached mappings, speed tiers, mixed models, and spend tiles; documents historical recalculation.

The full macOS SwiftPM suite could not be run in this Linux environment; GitHub's Build and Test check was still pending when inspected.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using gpt-6.1-sol | 𝕏

Comment thread Sources/OpenUsage/Providers/Codex/CodexUsagePricing.swift Outdated
@validatedev validatedev changed the title fix(codex): treat auto-review usage as free fix(codex): make auto-review free from October 6 Oct 6, 2026

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes Reviewed the timestamp-aware pricing correction in 4b5ae69 against the prior review at 445e2c3.

  • Restored Historical Estimates: Preserved dated paid-model estimates before the documented October 6, 2026 00:00 UTC cutoff, while keeping requests at or after it free.
  • Propagated Request Time: Required timestamps throughout shared Codex pricing and passed native, pi, and OpenCode request times into that policy.
  • Separated Cached Rates: Keyed OpenCode prepared rates by effective pricing model so historical and free requests cannot reuse each other's rates.
  • Scoped Carried Costs: Overrode pi's carried estimates only for free-era Codex auto-review, preserving earlier positive costs and ordinary provider behavior.
  • Expanded Boundary Coverage: Added exact assertions for both sides of the cutoff, UTC offsets, cached mappings, service tiers, fallback handling, and OpenCode cache order; aligned the documentation.

The macOS SwiftPM suite could not be run in this Linux environment. GitHub's Build and Test check was pending when inspected.

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@validatedev

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 6, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-06T12:40:43.872352Z 55092c7 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 4b5ae69d42

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Sources/OpenUsage/Providers/SpendTileMapper.swift Outdated

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes Reviewed 492b816 against the prior Pullfrog review at 4b5ae69, with the full PR diff as context.

  • Preserved Mixed-Period Visibility: Kept codex-auto-review in its own breakdown row even when historical paid estimates make its aggregate cost positive but below the normal folding threshold.
  • Added Regression Coverage: Asserted exact Last 30 Days totals, auto-review tokens and historical cost, and continued folding of ordinary small Luna usage into Other.
  • Updated Documentation And Screenshot: Documented mixed-period behavior and added a fixture-rendered screenshot showing the retained auto-review row.

The macOS SwiftPM suite could not be run in this Linux environment. GitHub's Build and Test check was still in progress when inspected.

Pullfrog  | View workflow run | Using gpt-6.1-sol | 𝕏

@validatedev

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Breezy!

Reviewed commit: 55092c7044

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant