Skip to content

Fix Claude scoped weekly pace - #2372

Merged
steipete merged 3 commits into
steipete:mainfrom
smkwray:agent/claude-scoped-weekly-pace
Jul 29, 2026
Merged

Fix Claude scoped weekly pace#2372
steipete merged 3 commits into
steipete:mainfrom
smkwray:agent/claude-scoped-weekly-pace

Conversation

@smkwray

@smkwray smkwray commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Summary

  • enable the existing pace projection for Claude extra rate windows
  • cover a model-scoped seven-day Fable only window in the Claude account-card regression test

Why

Claude model-scoped weekly limits are emitted as extra rate windows with a seven-day duration and reset date, so they contain everything the standard pace calculation needs. The extra-window pace helper was restricted to Codex and Antigravity, which left Claude's Fable only card showing usage and reset information but no reserve/deficit or run-out projection.

Impact

Claude scoped weekly cards now display the same pace detail as the main weekly card. Other providers and non-weekly extra windows remain unchanged.

Validation

  • git diff --check
  • release app target built successfully and the patched bundle was exercised with a live Claude Fable only card
  • portable repository checks and SwiftFormat passed
  • the focused Swift test could not run locally because this machine's standalone Command Line Tools installation lacks XCTest; upstream CI should exercise the added assertion
  • SwiftLint could not start locally because the standalone Command Line Tools installation lacks sourcekitdInProc.framework

@steipete
steipete force-pushed the agent/claude-scoped-weekly-pace branch from d7531ce to 47d3f8b Compare July 29, 2026 15:57
@steipete
steipete marked this pull request as ready for review July 29, 2026 15:57
@clawsweeper clawsweeper Bot added rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. P2 Normal priority bug or improvement with limited blast radius. labels Jul 29, 2026
@clawsweeper

clawsweeper Bot commented Jul 29, 2026

Copy link
Copy Markdown

Codex review: needs real behavior proof before merge. Reviewed July 29, 2026, 12:01 PM ET / 16:01 UTC.

ClawSweeper review

What this changes

The PR enables reserve/deficit pace projections for Claude model-scoped seven-day rate windows and adds regression coverage for both weekly and non-weekly Claude extra windows.

Merge readiness

Blocked until real behavior proof is added - 2 items remain

Keep this PR open. Current main still excludes Claude from the extra-window pace calculation, while this focused two-file patch enables only Claude’s seven-day scoped windows and preserves the no-pace behavior for other extra windows; it needs inspectable after-fix runtime proof before merge.

Priority: P2
Reviewed head: 47d3f8b7de899d2cfe9950fd5fa891729de35854

Review scores

Measure Result What it means
Overall readiness 🦪 silver shellfish (2/6) The implementation and focused regression tests are solid, but the required inspectable real-behavior proof is absent.
Proof confidence 🦪 silver shellfish (2/6) Needs real behavior proof before merge: The PR states that a live Claude Fable-only card was exercised, but it provides no inspectable after-fix artifact. Before merge, add a redacted menu capture, recording, terminal output, or runtime log that shows the scoped weekly card’s pace detail; redact account and private usage information. Updating the PR body should trigger a fresh ClawSweeper review, or a maintainer can comment @clawsweeper re-review. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Needs proof Needs real behavior proof before merge: The PR states that a live Claude Fable-only card was exercised, but it provides no inspectable after-fix artifact. Before merge, add a redacted menu capture, recording, terminal output, or runtime log that shows the scoped weekly card’s pace detail; redact account and private usage information. Updating the PR body should trigger a fresh ClawSweeper review, or a maintainer can comment @clawsweeper re-review. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
Evidence reviewed 4 items Current-main behavior: At the PR base, the extra-window pace helper accepts only Codex and Antigravity, so Claude scoped weekly windows cannot receive pace detail.
Proposed narrow fix: The current PR head first rejects Claude windows unless their duration is exactly 10,080 minutes, then admits Claude alongside the two existing providers; this confines the new display behavior to weekly Claude extras.
Regression coverage: The PR extends the Claude menu-card tests to assert pace detail for the scoped Fable weekly window and no pace detail for a non-weekly extra window.
Findings None None.
Security None None.

How this fits together

CodexBar turns each provider usage snapshot into menu-card metrics shown from the macOS menu bar. Claude’s model-scoped quota limits arrive as extra rate windows, and the pace helper decides whether a metric gets reserve/deficit and run-out details or only usage and reset information.

flowchart LR
    A[Claude usage snapshot] --> B[Scoped extra rate windows]
    B --> C[Menu-card metric builder]
    C --> D{Seven-day Claude window?}
    D -->|Yes| E[Pace calculation]
    D -->|No| F[Usage and reset detail]
    E --> G[Reserve or deficit display]
    F --> H[Claude menu card]
    G --> H
Loading

Before merge

  • Add real behavior proof - Needs real behavior proof before merge: The PR states that a live Claude Fable-only card was exercised, but it provides no inspectable after-fix artifact. Before merge, add a redacted menu capture, recording, terminal output, or runtime log that shows the scoped weekly card’s pace detail; redact account and private usage information. Updating the PR body should trigger a fresh ClawSweeper review, or a maintainer can comment @clawsweeper re-review. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
  • Resolve merge risk (P1) - The PR body reports a live Claude-card exercise, but there is no inspectable redacted screenshot, recording, terminal output, or runtime log showing the new pace detail; that leaves the real provider-to-menu-card rendering path unverified before merge.
Agent review details

Security

None.

Review metrics

Metric Value Why it matters
Patch surface 2 files affected; 32 additions, 3 deletions The implementation is tightly scoped to pace eligibility and Claude card regression coverage.

Root-cause cluster

Relationship: fixed_by_candidate
Canonical: #2392
Summary: This PR directly implements the closed scoped-weekly pace request; the related menu-bar layout-token PR is adjacent but changes a separate visible surface.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Merge-risk options

Maintainer options:

  1. Decide the mitigation before merge
    Keep the provider-specific seven-day gate, merge it only after a redacted after-fix capture proves a real Claude scoped weekly card displays the expected reserve/deficit and projection, and retain the non-weekly regression guard.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Technical review

Best possible solution:

Keep the provider-specific seven-day gate, merge it only after a redacted after-fix capture proves a real Claude scoped weekly card displays the expected reserve/deficit and projection, and retain the non-weekly regression guard.

Do we have a high-confidence way to reproduce the issue?

Yes, source-reproducible: a Claude extra window with windowMinutes == 10080 reaches the existing provider gate on current main and returns no pace detail because Claude is excluded. The PR’s focused model construction and assertions provide a high-confidence regression path, though this review did not execute it.

Is this the best way to solve the issue?

Yes. Adding Claude to the existing pace path while explicitly limiting its extra windows to seven days is the narrowest maintainable repair, and the companion non-weekly test protects the intended provider-specific boundary.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against c52b0efa13b0.

Labels

Label justifications:

  • P2: This fixes missing pace detail on a bounded Claude quota-card workflow, with no evidence of message delivery, authentication, security, or availability impact.
  • rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦪 silver shellfish and patch quality is 🐚 platinum hermit.
  • status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask. Needs real behavior proof before merge: The PR states that a live Claude Fable-only card was exercised, but it provides no inspectable after-fix artifact. Before merge, add a redacted menu capture, recording, terminal output, or runtime log that shows the scoped weekly card’s pace detail; redact account and private usage information. Updating the PR body should trigger a fresh ClawSweeper review, or a maintainer can comment @clawsweeper re-review. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.

Evidence

What I checked:

Likely related people:

  • steipete: Authored the latest PR-head correction that constrains Claude pace rendering to weekly windows after the initial provider expansion. (role: recent area contributor; confidence: medium; commits: 47d3f8b7de89; files: Sources/CodexBar/MenuCardView+ModelHelpers.swift)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Add redacted after-fix evidence from a real Claude scoped weekly card showing reserve/deficit and the corresponding projection.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

Copilot AI review requested due to automatic review settings July 29, 2026 21:20
@clawsweeper

clawsweeper Bot commented Jul 29, 2026

Copy link
Copy Markdown

ClawSweeper status: review started.

I am starting a fresh review of this pull request: Fix Claude scoped weekly pace This is item 1/1 in the current shard. Shard 0/1.

This placeholder means the worker is alive and reading the current context. I will edit this same comment with the actual review when the claws are done clicking.

Crustacean status: shell secured, claws on keyboard, evidence pebbles being sorted.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR enables pace projection details for Claude model-scoped weekly “extra rate windows” (7-day windows) so scoped weekly cards render the same reserve/deficit and run-out projection as the main weekly card, while keeping non-weekly extra windows unchanged.

Changes:

  • Allow Claude weekly (10080-minute) extra rate windows to produce PaceDetail in the menu card model helper.
  • Extend the Claude swap-account menu card regression test to assert pace details render for the Fable only scoped weekly window.
  • Add a regression test ensuring Claude non-weekly extra windows do not render pace detail fields.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
Sources/CodexBar/MenuCardView+ModelHelpers.swift Enables pace detail rendering for Claude weekly extra rate windows while preserving existing behavior for other non-weekly windows/providers.
Tests/CodexBarTests/MenuCardClaudeSwapAccountTests.swift Adds/extends regression coverage to ensure Claude scoped weekly pace details appear and non-weekly extras remain without pace detail.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@steipete
steipete merged commit 5e36df1 into steipete:main Jul 29, 2026
9 checks passed
@steipete

Copy link
Copy Markdown
Owner

Merged after full verification. Claude model-scoped seven-day windows (e.g. "Fable only") now show reserve/deficit pace detail.

Narrowed during review: the original guard enabled pace for any Claude extra window, which would have silently applied to any future 300-minute Claude window too — broader than the weekly fix intended. It's now restricted to windowMinutes == 10080, with negative coverage proving a non-weekly Claude extra window gets no pace detail.

Note on CI: the aggregate gate had been failing across reruns because swift-test-macos was skipped — the branch was stale enough that the path-change filter saw no macOS-relevant changes. Merging main in regenerated that comparison and the macOS shards then ran green. Thanks @smkwray — nice first contribution!

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

Labels

P2 Normal priority bug or improvement with limited blast radius. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants