fix: bust persisted query cache on deploy - #2058
Open
alanpeixinho wants to merge 1 commit into
Open
Conversation
Contributor
Author
|
Leaving here so it is documented, we had some discussion on calls about solving this by using local memory for cache or sessionStorage. However there are a few drawbacks there.
|
Member
|
I made a comment about the sessionStorage then I saw your comment about it. Ok |
felipebergamin
approved these changes
Aug 21, 2026
- Guard pageOrigins so a mismatched origins shape cannot crash /tree - Version the persist buster so stale cache blobs are dropped on deploy - Build failure if no VITE_DASHBOARD_VERSION is set. Closes kernelci#2048 Signed-off-by: Alan Peixinho <alan.peixinho@profusion.mobi>
alanpeixinho
force-pushed
the
fix/frontend-stale-cache
branch
from
August 24, 2026 18:24
ba93527 to
a73930f
Compare
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.
What it is
Fixes
/treecrashing withCannot read properties of undefined (reading 'map')when a persisted React Query cache holds anoriginspayload withoutcheckout_origins/test_origins(#2048).OriginSelecttreats missing origin lists as[]so.mapcannot throw.VITE_CACHE_BUSTER(dashboard version, orbuild-<timestamp>if empty) so a new deploy drops stale blobs.How to test
Dev persist uses
sessionStorage(prod:localStorage). Recover withsessionStorage.clear()then reload./treeand confirm the origin dropdown works.Expect: no “Something went wrong!”; origins refetch; dropdown populated.
3. Reload without editing the cache: same
buster→ hydrates, no crash.Closes #2048