-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
refactor(walletconnect): migrate to WalletKit and implement multi-chain support #13515
base: main
Are you sure you want to change the base?
Conversation
CLA Signature Action: Thank you for your submission, we really appreciate it. We ask that you all read and sign our Contributor License Agreement before we can accept your contribution. You can sign the CLA by just by adding a comment to this pull request with this exact sentence:
By commenting with the above message you are agreeing to the terms of the CLA. Your account will be recorded as agreeing to our CLA so you don't need to sign it again for future contributions to this repository. 1 out of 2 committers have signed the CLA. |
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.
Nicely done
This reverts commit 88a6ba2.
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #13515 +/- ##
==========================================
+ Coverage 62.53% 62.74% +0.21%
==========================================
Files 2005 2014 +9
Lines 44261 44396 +135
Branches 6006 6029 +23
==========================================
+ Hits 27679 27857 +178
+ Misses 14748 14707 -41
+ Partials 1834 1832 -2 ☔ View full report in Codecov by Sentry. |
Screen.Recording.2025-02-20.at.10.59.11.AM.mov |
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.
I have read the CLA Document and I hereby sign the CLA
This reverts commit bde6638.
Critical Issue Screen.Recording.2025-02-20.at.11.48.38.AM.movNote: Screen.Recording.2025-02-20.at.11.52.04.AM.mov |
Trying to sign after switching to a chain that hasn't been approved yet fails: Screen.Recording.2025-02-20.at.11.58.07.AM.movStacktrace:
|
|
Resolved! Regarding the critical issue where the wallet doesn’t automatically switch chains from a non-synced state: Root Cause: This was a dapp-side bug, not a mobile app issue. When reconnecting after switching to Arbitrum, the dapp sent Verification: Testing confirmed that when the dapp switches to Ethereum, then Arbitrum, and signs, the mobile app properly switches chains. Let me know if you need further clarification or additional test cases! |
The wallet should inform the dapp the current active chain, otherwise the dapp might think they're making a request for one chain when in reality it is requesting for another. In reality, regardless of what the dapp sends, the wallet needs to act as a safeguard and switch to the chain being requested. |
The recommended approach is for the wallet to accept requests in any of the approved chains in the session. Users can switch the chain on the dapp multiple times before sending a request and the wallet will not get notified at all of these local (dapp side) chain switches because
|
Description
This PR completes the migration from WalletConnect SE SDK (a wrapper adding an unnecessary layer over WalletConnect) to WalletKit, improving our existing multi-chain support implementation.
Motivation
Solution
Key implementation details:
getPermittedChains
utility for better chain permission managementRelated issues
Manual testing steps
Screenshots/Recordings
Before
After
Pre-merge author checklist
Pre-merge reviewer checklist