-
Notifications
You must be signed in to change notification settings - Fork 24.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix bug in device ID collision handling, add tests (#45010)
Summary: Pull Request resolved: #45010 D46482492 added logic for handing off state across "device" connections that have the same ID. This logic currently has no test coverage. It also contains a bug whereby the new device's pages are removed from the target listing endpoint (`/json`) when the *old* device's socket is closed. This diff adds tests and fixes the bug. Changelog: [General][Fixed] inspector-proxy no longer accidentally detaches connected devices. ## Next steps It seems that the device ID handoff logic exists to paper over a deeper problem with the inspector proxy protocol (or its implementation in React Native): The React Native runtime should not routinely be creating new "device" connections without tearing down previous ones. In followup diffs, I'll explore changing this behaviour for Fusebox, based on the new test coverage. Reviewed By: robhogan Differential Revision: D51013056 fbshipit-source-id: e0c17678cc747366a3b75cef18ca2a722fc93acd
- Loading branch information
1 parent
9491ded
commit 4c6bff0
Showing
5 changed files
with
360 additions
and
4 deletions.
There are no files selected for viewing
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
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
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
Oops, something went wrong.