-
Notifications
You must be signed in to change notification settings - Fork 22
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
Update Wallet Adapter #189
Update Wallet Adapter #189
Conversation
@jordansexton is attempting to deploy a commit to the Cardinal Labs Team on Vercel. A member of the Team first needs to authorize it. |
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
I can see https://github.com/cardinal-labs/cardinal-staking-ui has the exact same issue right now. Once this is merged I'll send a PR. |
have dealt with this issue before, related to a specific version of web3js dependency, https://vercel.com/cardinal-labs/cardinal-rental-ui/3bHQmQd3JvjM4CgCgk346fYfqaUL |
From the yarn.lock file I can see five (!!!!!) versions of web3.js are getting included as dependencies. Expand for web3.js versions
|
ya looking...its the version mismatch in web3.js where some versions allow |
we will sort this but it sounds like the wallet adapter doesnt disconnect if we use the list of wallets in useMemo |
I've pushed another commit that forces one version of web3.js. |
Looking into this! |
Disconnecting works for me, at least with Backpack? What behavior are you seeing? |
I've pushed another commit that removes an invalid connection.getMultipleAccountsInfo(b, config as web3.Commitment) |
I can't run a full production build locally because of this:
|
yes - the versions for web3.js are all fucked up because of those breaking changes in web3.js to getMultipleAccounts config -- The main branch now allows u to build locally without sentry API key, thanks for this, we will take out the changes - mainly it sounds like wallet adapters in useMemo so they stay as a memoized constant and rebase and see if that allows wallet-adapter upgrade without the wallet constantly disconnecting |
78b3d21
to
82764d1
Compare
rebased and fixed the deps stuff...and voila its actually working 😂 I think the main thing we didnt have was just the useMemo around the wallet list <3 |
Sweet! Yeah, useMemo missing, and the versions of the wallet adapter deps were a bit out of wack. |
@@ -182,6 +183,74 @@ export const deserializeAccountInfos = ( | |||
...(accountInfo as AccountInfo<Buffer>), | |||
parsed: accountData.parsed?.info as ParsedTokenAccountData, | |||
} | |||
// taken from account deserialization in splToken getMintInfo | |||
} else if ( |
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.
cc @gchatz22 for 👀 had to add this absolutely heinous account deserialization code to handle the non "parsed" encoding of getMultipleAccounts that no longer is allowed in newer web3.js - this is some code i was trying to avoid adding for awhile until we just went to new token client
this issue has plagued us for so long, next PR ill just upgrade it to the newer spl-token client, but I believe well have to update everywhere we read from mint / tokenaccounts to use that new type since its slightly different so covering that in separate PR
Thanks for the add @jordansexton 👍
big ups @jordansexton 🤝 |
Awesome, glad it's working! |
Hello, does it work for any of you guys? For me selecting |
Same here, am using chrome v100.0.4896.127 on a Huawei P30 Pro (Android 10; VOG-AL 10 Build/HUAWEIVOG-AL10), have both fakewallet and phantom mobile v22.11.14 installed. cardinal-mwa-fukt.mp4 |
This PR updates Wallet Adapter to the latest RC which includes Wallet Standard and MWA support.
I ran prettier before and after and added the
docs
dir to ignore.