GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||
GeezerVison is showing github.com — fix(usage): attribute account limits per provider instance by derektrimm · Pull Request #7133 · pingdotgg/t3code Conversation
|
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
One convention finding: the new service test aliases the service module's layer export instead of importing the module as a namespace. Everything else in the touched Effect code (subpath namespace imports, Context.Service shape, dependency acquisition via yield*, test-only Layer.succeed seams, runPromise confined to test boundaries) matches the conventions.
Posted via Macroscope — Effect Service Conventions
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
UI consistency review of the Limits strip / hover card changes. One consistency violation in the new instance captions, plus a smaller duplicated-derivation note. The Tailwind/markup work itself (extracted HoverWindowRow / SectionWindowRow, truncation with title, single-group markup parity) looks correct and preserves the previous geometry.
Posted via Macroscope — UI Consistency
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
ApprovabilityVerdict: Skipped Macroscope did not run approvability analysis for this PR. Macroscope could not determine whether this PR modifies its approvability configuration, so the PR was not approved automatically. A PR that may change the rules that govern approval is never approved automatically. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
One finding: the new environment caption bypasses the app-wide environment display-label contract. Details inline.
Posted via Macroscope — UI Consistency
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
c977905 to
5d305d4
Compare
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
One repo-enforced convention violation (manual Effect runners in a new test file) plus a small documentation-placement issue. Details inline.
Posted via Macroscope — Effect Service Conventions
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
With several Claude or Codex instances configured, the limits cache kept one snapshot per provider, so accounts overwrote each other, the out-of-order guard let the busiest account suppress the rest, and the shared-home transcript seed presented one account's usage as everyone's. Snapshots are now keyed by (provider, instance): ingestion forwards the providerInstanceId the envelope already carries; cache rows written before instance attribution migrate to the driver's default instance and stand until live data for another instance of the same provider proves they may belong to somebody else; transcript seeding only reads sessions dirs owned by exactly one instance, compared by filesystem identity, with disabled instances counting as owners; rows for deleted instances are evicted and disabled instances' rows are hidden until re-enabled. The contract version moves to 2 - a v1 client would merge per-instance snapshots freshest-wins per provider, which is the original bug on the mixed-version path, so it skips them instead; the v2 client accepts both versions. The client keeps one row per (environment, provider, instance) - never merged across environments, whose clocks cannot arbitrate freshness for each other, though byte-identical rows from same-machine environments collapse. Rows are labeled from the instance display name already on the wire (never the authenticated email, which the provider UI deliberately blurs), and single-row providers render markup identical to the single-account original.
Untouched windows arrive as 0% used with no reset clock - the reset only exists once a window has traffic. Passing them through gave every Claude card a permanent 0% row per novel provider-side window slug, which reads as information and is not. They are dropped in the normalizer - the one place windows are assembled - so every client keeps rendering the array as-is, and a window appears the moment it first carries usage, which is also when its reset clock starts meaning something.
- Transcript seeding: a shadow-overlay instance seeds from its layout, not its CODEX_HOME env - spawn pins the overlay, so the env value never reaches the CLI (Bugbot). - Multi-row groups render a per-row empty state instead of a bare caption when an instance has no windows, in both the hover card and the section (Macroscope). - Environment captions fall back to the environment id when no label is set, so two unlabeled environments stay distinguishable (Macroscope, suggestion applied). - Captions resolve through the app-wide instance display-name contract (getProviderInstanceEntry), naming accounts the way the picker and provider settings do; the duplicate-label fallback becomes a rare safety net (Macroscope, suggestion applied). - The render key reuses the merge's own legacy-id mapping instead of re-deriving it; the service test imports the module as a namespace (Macroscope, suggestions applied). - The byte-identical duplicate collapse keeps its behavior with the module doc now stating the exception precisely: identical content under one instance id is the same underlying reading seen twice.
…bel contract The caption read entry.target.label raw, so a blank label rendered a dangling separator and the primary environment named itself differently from every picker. The atom now carries the target's isPrimary flag and RowCaption resolves through resolveEnvironmentOptionLabel - blank labels normalize, the local machine reads "This device" here exactly as it does everywhere else, and the id fallback comes from the one shared contract.
windowHasTraffic ran only in the provider parsers, but windows are also assembled in the streamed Claude single-window patch and reloaded verbatim from pre-upgrade cache rows - either path could carry a bare 0%/no-reset window onto Limits and persist it back to disk. The filter now runs at the service's single write path and on cache load, so the invariant holds for every entry point.
…snapshots clear the row Two edges of the untouched-window filter, both review findings: - The single-window patch removed the existing window by id before store's filter ran, so an untouched streamed event deleted the metered window it named. Untouched patches now leave the previous set alone entirely. - Filtering inside claudeUsageSnapshotFromUnknown made an applicable all-untouched snapshot indistinguishable from rate_limits: null, so stale meters survived a reset forever. The parser now says whether rate limits apply: not-applicable keeps what was known, applicable-but-empty clears the row. Also per conventions: the standalone service tests run under it.live instead of a manual Effect.runPromise, and the HostProcessEnvironment acquisition moved up with the other dependencies so the migratedSlots doc block stays attached to its declaration.
3ba8c84 to
b009cb9
Compare
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Want fixes drafted automatically? Bugbot Autofix can create code changes for findings. A team admin can enable Autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit b009cb9. Configure here.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
The v1-migration comments said only live data settles or evicts a migrated row, but the seed path stores through the same write and evicts too. That is the intended behavior: a sole-owner transcript dir is the same evidence of a distinct account that a live event is, and a default instance with transcripts of its own re-seeds in the same pass. Reword the comments to match, and pin both halves with a test.
The streamed rate_limit_event mirrors the anthropic-ratelimit-unified-* -utilization response headers, which are a 0-1 fraction, while the usage control response reports 0-100. Both converters clamped without scaling, so the binding window - the only one the stream names - rendered at 1/100th (0.87 shown as 1% on a week the account flags as warning). Measured on one account at one moment: header 0.11, usage endpoint 12.0. Reported by Moinax on pingdotgg#5739.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Verified against the current head locally. The focused account-limits suite passes (90 tests), scoped server/web/contracts typechecks pass, and targeted lint/format checks are clean. The per-instance cache keying, v1 migration, transcript ownership rules, client grouping, and streamed Claude utilization scaling address the reproduced correctness gaps in #5739 without changing single-account presentation.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
I verified this stack locally: 90 focused account-limits tests, scoped server/web/contracts typechecks, and targeted lint/format checks pass, and I left an approval. I opened derektrimm#1 on top with the remaining verified #5739 review fixes: backward-clock seed recovery, short-read decoding, a three-second Claude usage-request bound, the failing Effect namespace-import convention, and focused regression coverage (159 tests passing on the combined stack). |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Closing: this fixed the AccountLimitsService from #5739, which was closed in favor of the #1732 direction, so there is no longer code on main for this to patch. The attribution issue itself (limits keyed per account, not per provider type) still applies to any implementation and is written up in #1732 (comment) |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…y editor can do the same things Every editor (ordinary or scheduled thread, lead, any writer role) lists and may call the same T3 tools on /mcp/editor; read-only tasks use /mcp/reader with a closed list applied at listing and call time; browser agents and researchers keep their narrow endpoints. Delegation stops two levels below a top-level thread, counted on the server from lineage. Harness subagent and web tools are off for every thread, replaced by delegate_task, web_search and web_fetch. Managed Claude writers keep the coding set of built-ins (Henry's choice). Settings shows each role's class. Fixes T3-532 (pingdotgg#7133). Co-Authored-By: Claude Opus 5.5 <[email protected]> Build: pingdotgg#7133
…se query T3-532 removed the delegated-worker refusal from t3_champions_learning_search action query; only a linked environment is still refused there, so the description now says just that. Found in T3-532's qualifying review. Co-Authored-By: Claude Opus 5.5 <[email protected]> Build: pingdotgg#7133
agentAccessSettings derived the permission class inside the settings read, so a settings or project read failure, or a server without a settings service, answered readOnly false and minted a read-only task the editor credential with the whole catalogue. The class rests on the thread alone: it is now read first, only browser and device access fall back when settings fail, and a thread that can't be read is treated as read-only. Also moves toolkitRegistration's comment back above it. Found in T3-532's qualifying review (DeepSeek S532-3, S532-4). Co-Authored-By: Claude Opus 5.5 <[email protected]> Build: pingdotgg#7133
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.