Fix missing asset errors in runtime manifest bundles #8981
Merged
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.
↪️ Pull Request
This PR fixes an issue where runtime manifest bundles could cause bundles to be missing from the register code, causing a runtime error (
Error: Could not resolve bundle with id abKQ5
).This issue would occur when a runtime manifest bundle was split out from the bundle group entry but one (or more) of it's parents runtimes had already been processed, causing the new bundle to be missing from the register code.
Previously we were processing the bundles in reverse order to handle this issue, but that only minimised the issue and didn't eliminate it completely. The fix here is to process the bundles in reverse topological order which means all child bundles will be processed before their parents.
🚨 Test instructions
As this is just a slight modification of the existing code I haven't added more tests scenarios.
✔️ PR Todo