fix(rspack): refresh http import lockfile redirect - #503
Merged
Merged
Conversation
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 changed
Regenerate the
http-importlockfile as a single redirect-aware entry:https://www.unpkg.com/the-answernow recordsresolvedas the final URLhttps://www.unpkg.com/the-answer@1.0.0/dist/the-answer.jsafter followingthe unpkg 301 redirect.
URL's entry is authoritative.
integrityandcontent_typeare unchanged (the content is identical);valid_untilis refreshed from the re-fetch.Why
Follow-up to #502. That PR repaired the frozen lockfile check but kept the
legacy two-entry shape written by the pre-fix Rspack. Since
Rspack #15609, the
HttpUriPlugin preserves the original URL's locked entry through redirects and
records the final resolved URL on it, so a clean regeneration with
frozen: falseproduces a single entry. This keeps the production buildpassing with
experiments.buildHttp.frozenenabled by default.Validation
pnpm install --filter @rspack-example/http-import... --frozen-lockfilepnpm --filter @rspack-example/http-import build(production mode, frozen lockfile enforced)Related