Repository navigation
feat: add Service Worker network interception #12565
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
Closed
Ross Wollman (rwoll)
wants to merge
27
commits into
microsoft:main
from
rwoll:feat/sw-init-interception
Closed
Changes from all commits
Commits
Show all changes
27 commits
Select commit
Hold shift + click to select a range
c253bf1
wip: feat: service worker interception
rwoll eb50e9b
unfocus tests
rwoll c34936d
remove assumption that Request et. al. belong to frame
rwoll ed4c8c9
fail tests best on browser
rwoll 347cd0f
nit: avoid conditionals in the Request constructor bits
rwoll 4af24ca
test: add stub tests
rwoll 779a432
test: add more placeholder tests
rwoll f6d9c4f
tighten SDKObject scopes
rwoll b7b7cb1
wip: use CRNetworkManager for Service Workers, too
rwoll c02c73b
wip: experiment with attachment fix
rwoll d7df22b
allow init to fail (SW might detach before we get to it)
rwoll 765ed30
wip: add initial HAR bits, cleanups, tests
rwoll 4caa04a
test: service worker interception with importScripts
rwoll 4af9b64
move CRServiceWorker to own file
rwoll 6a4168d
dynamically set interception
rwoll adfc1f0
nit: listener registration
rwoll 8fc4b40
add SW barrier, fill in more of HAR
rwoll 0a70ece
nit: use alias for TODOs
rwoll e2d165c
fix leaky SW listener
rwoll ddf594e
address review feedback
rwoll 4653b25
tests: properly await routing
rwoll 16c11ea
review feedback; mechanical cleanups
rwoll 608f613
move _setParentNetworkManagerForServiceWorker onto CRBrowserContext
rwoll 95147bf
inline _requestStarted
rwoll 8ae6f23
ensure only Service Worker-identified requests are adoptable
rwoll e47f166
simplify adoptions (assuming upstream bug gets fixed)
rwoll 4200842
remove adoption code (depends on upstream CR patch)
rwoll File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const page = this.request()._frame?._page;