Repository navigation
Keep the refresh for extension wallets, and the other permanence cache review fixes - #2330
Merged
Merged
Conversation
…e review fixes An extension wallet whose earlier credits reading was none or zero, with AR paid directly, lost the "Refresh credits used" button and the "as of" note. The AR-only tile now carries both. Also: a clock that moved backward is stale, not current; the AR count is re-checked after a minute, not half an hour, for ten minutes after this app spends; an open no longer joins a read that began before the last spend; and both writers to local storage check for a logout after the store opens. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017ksUKnnC1PGwNoUh6JNwZt
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 24 minutes. View limit details
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 |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017ksUKnnC1PGwNoUh6JNwZt
This was referenced Oct 21, 2026
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This follows #2326, which merged before its review fixes landed. It makes the permanence panel's cache keep the refresh button for extension wallets, and closes the other gaps an independent review found. The review found no path where a hook can break or stall an upload, transaction post or top-up.
Needs your judgement: the shorter AR re-check after a spend (1 minute, for 10 minutes after the app last spent). Both values are constants at the top of
lib/permanence/permanence_cache.dart.Measured in a browser on a production build, logged in, after a sync: before #2326, 11 requests on the first open and 4 on every open after. After #2326, 4 on the first open (2 GraphQL, price, rate), then 0, then 0.
Fixes
lib/permanence/permanence_panel.dart:652(arOnly),:692,:703permanence_panel_test.dart: "of none, beside AR paid directly, still offers a refresh"permanence_cache.dart:36(_within)permanence_cache_test.dart: "a clock that moved backward makes every kept figure stale"permanence_cache.dart:407,:433permanence_cache.dart:308,:382permanence_cache.dart:351,:456lib/turbo/services/upload_service.dart(unchanged)upload_service_test.dart: "leaves the credits used alone when the item is refused"Fails before
Each new cache and panel test fails on
devwithout the fix: I putdev's versions ofpermanence_cache.dartandpermanence_panel.dartback and reran. Five failed: backward clock, AR re-check after a spend, not joining a read from before a spend, logout while the store opens, and the extension-wallet refresh. The refused-post test and the "joined when nothing happened between" test pin behaviour that already held, so they pass before and after.Not covered
Hooks without their own test:
postTx,uploadTx, the upload repository's two completion callbacks, the manifest repository, and the card and crypto top-up blocs. Only the Turbo data item hook and logout are tested directly.loadNetworkCoststays: the panel's tests still use it. The value types (SpendLookup,NetworkCost) stay in the widget file, so the cache file imports it; moving them is a separate change.Not seen on screen: the "as of" text and the button layout.
Independent check
A separate agent checked each fix against the earlier review's findings and found them fixed. It reported nothing that blocks a merge. Known limits, not changed here:
Two code comments were reworded to drop "just".
🤖 Generated with Claude Code
https://claude.ai/code/session_017ksUKnnC1PGwNoUh6JNwZt