Improve Ledger device detection and MV3 compatibility#3821
Open
hyphenized wants to merge 3 commits intomainfrom
Open
Improve Ledger device detection and MV3 compatibility#3821hyphenized wants to merge 3 commits intomainfrom
hyphenized wants to merge 3 commits intomainfrom
Conversation
This queries Ledger devices by vendorId instead of using a hardcoded list of known productId/vendorId matches. This is the same approach used by the underlying transport library and prevents cases where the Ledger does not show up in the list of devices to pair due to the productId being changed by a recent ledger app update. `TestedProductId` assertion was removed as TransportWebUSB already filters compatible devices.
1afc5dd to
d7528f0
Compare
Contributor
|
Matt gave this a shot and didn't see a significant improvement unf. Nonetheless I think it's a good change so expect to land shortly. |
Contributor
Author
He still has issues with his ledger? Hmmmm I wonder if there's something specific to his webusb device connection or if there are any notable errors popping in the worker during connection/sign |
Contributor
|
Yah will see if we can get some more/better logs meantime. |
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.
Prevents pairing failures by replacing the hardcoded productId list with vendorId based querying. This automatically supports new Ledger devices and firmware updates that can change internal productIds.
Added a helper function to verify the Ledger has the Ethereum app open before fully commiting to the connection flow. Within the service, supported device checks where removed as the underlying transport library already handles device compatibility filtering.
This PR also fixes compatibility issues related to event handlers with Manifest V3. Preventing race conditions where USB connect/disconnect events could be missed if handlers weren't registered in time.
These where related to the following warnings:

Notes:
If Chrome forgets the USB device pairing, Users will need to reconnect via the tabbed onboarding flow. This is a browser limitation since USB device pairing can only be requested from certain contexts, not from the extension popup or background processes.
Testing:
Tested with Nano S, Nano X, Nano S Plus. Connectivity issue found with NanoS after software update.
Latest build: extension-builds-3821 (as of Fri, 29 Aug 2025 01:43:02 GMT).