New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix web extension issues #8000
Merged
Merged
Fix web extension issues #8000
Conversation
This file contains 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
Looks like the content hashing tests are failing due to the changes in EDIT: Found and fixed the issue, should be working now. |
Benchmark ResultsKitchen Sink 🚨
Timings
Cold BundlesNo bundles found, this is probably a failed build... Cached BundlesNo bundles found, this is probably a failed build... React HackerNews ✅
Timings
Cold BundlesNo bundle changes detected. Cached BundlesNo bundle changes detected. AtlasKit Editor ✅
Timings
Cold Bundles
Cached Bundles
Three.js ✅
Timings
Cold BundlesNo bundle changes detected. Cached BundlesNo bundle changes detected. |
devongovett
reviewed
May 8, 2022
devongovett
reviewed
May 8, 2022
devongovett
reviewed
May 8, 2022
devongovett
approved these changes
May 23, 2022
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.
↪️ Pull Request
Fixes #7997
There were some issues with the web extension schema that this PR fixes. However, the main change is making the dependency merging logic more robust, which fixes an issue where two dependencies for an asset added as
needsStableName: true
andneedsStableName: false
but otherwise identical would sometimes result in a bundle withneedsStableName: false
. This was because the merging logic would simply update the first dependency's options with the newer dependency's options, when in reality the merged dependency should have a stable name if either source dependency needed it.I also applied this logic to all the other fields that weren't factored into the dependency ID. For instance, if the dependency is optional in one dependency but not the other, the merged dependency should not be optional. The only field I wasn't sure about was
bundleBehavior
; I'm just guessing that the precedence should be'isolated'
>'inline'
>null
. IMObundleBehavior
should actually be factored into the dependency ID but I wasn't sure so I didn't change that.💻 Examples
manifest.json
:Previously this manifest resulted in the
popup.html
file receiving a content hash, which is undesired behavior becauseweb_accessible_resources
aren't really that accessible if their names aren't constant. (Ifpopup.html
were only present inweb_accessible_resources
and not inaction
, however, it would work)This inconsistency is now fixed so if either dependency needs a stable name, the final merged dependency does too.