fix: refetch queries after a refreshAll navigation when the cached query survives it - #16546
Open
Nic-Polumeyv wants to merge 5 commits into
Open
fix: refetch queries after a refreshAll navigation when the cached query survives it#16546Nic-Polumeyv wants to merge 5 commits into
Nic-Polumeyv wants to merge 5 commits into
Conversation
|
Install the latest version of pnpm add https://pkg.svelte.dev/@sveltejs/kit/c/4df372e75ae1f673831e838cbdc68fd073f4cc8cOpen in Note This PR is from a fork. A maintainer must approve approve each commit before it can be built and installed. |
🦋 Changeset detectedLatest commit: 4df372e The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
This was referenced Jul 27, 2026
…pped resolve.conditions
Nic-Polumeyv
force-pushed
the
fix-remote-query-reset-lost-v3
branch
from
August 1, 2026 03:09
b2e55e5 to
4df372e
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.
Replaces #16453 now that main is winding down; fixes #16444.
#promise ??= this.#run()compiles to an unconditional$.set(sveltejs/svelte#18592), so a render that evaluates while the resetting batch from arefreshAllnavigation is still pending reads the pre-reset promise through the batch overlay and writes it straight back, erasing the reset. The deferred restart inclient.jsthen sees a non-null promise and never refetches. Whether the cached query survives the navigation at all is GC timing, which is why this mostly shows up in Firefox.This affects any
refreshAllnavigation: remote form redirects,applyAction,goto(url, { refreshAll: true }). Verified against the reproduction in #16444 on version-3 in Firefox: 10/10 stale before, 0/10 after, with the??=line being the only difference. The spec fails without the runtime change.