Open idelburgo-iomob opened 1 year ago
Hey, @idelburgo-iomob can you list all the wallets that you use to test deep link flow?
Sure, thanks for your answer @jakubuid Tried the following (all of them appear under v2 in the explorer)
Maybe I'm doing something wrong, but as the example wallet is working perfectly I can't see what. Followed documentation and all the examples.
We're aware of that and we're working with them closely to add the correct support for deep link flow ASAP Thanks for pointing out this
Hi @jakubuid I had the same issue. I tried to use Wallet Connect V2 to initialize a session to TrustWallet via the DeepLink Android. But I only link to Trust Wallet and don't appear anything after. Expect: link opens TrustWallet through Wallet Connect V2 and the confirmation modal appears to accept the connection session I glad if you can support me. Thank in advance
@jakubuid in 20 days v1 will be shutoff. Is there any estimation of when will this be solved? As I need to fully implement it and test before that date.
Hey all, we work closely with those wallets to add the correct support for deep links, see the following:
Yeah, same issue. I've opened this before: https://github.com/WalletConnect/WalletConnectKotlinV2/issues/793 It seems that while wallets support v2, issue in sdk prevented deeplinks from working.
For now im waiting confirmation from WalletConnect team on updated and working wallets, before our team starts any work on integration.
Trust - within the latest update on PlayStore - deep linking flow works
It seems that while wallets support v2, issue in sdk prevented deeplinks from working.
The above is true only for Auth use case -we're planning to release a new sdk version till EOW
Trust - within the latest update on PlayStore - deep linking flow works
It seems that while wallets support v2, issue in sdk prevented deeplinks from working.
The above is true only for Auth use case -we're planning to release a new sdk version till EOW
So this won't work in my case, using Core + Sign SDKs? I need to sign a message and be able to "sendTransaction"
The above is true only for Auth use case -we're planning to release a new sdk version till EOW
So fixed sdk is not out yet? As the issue was closed i thought you had released fixed version, and all it would take is for wallets to update and release versions with the fix. Why close issue if fixed sdk is not even released?
I tested with my app, and after updating TrustWallet, still happening the same. Are you/them checking with deeplinks from Android native (kotlin) apps? (Not from React Native or other hybrid apps). @jakubuid
TrustWallet - version 7.24.2 - deeplinking flow working with https://github.com/WalletConnect/WalletConnectKotlinV2/tree/develop/samples/dapp supporting Core + Sign
As far as I can see it is using Web3Modal SDK. Am I right? Im using Core + Sign. Won't it work with them? Im using [Core 1.15.0, Sign 2.13.0], should I try the next one or this is not the problem?
Web3Modal appears to be in alpha, so can't rely on it
I have the same case with separate wallets and need help to make WC2 work somehow with some wallets.
For Trust Wallet, the signing process only functions correctly when we send the sign body in the format of ["$msg", "$account"]. And after that signature is not what I expect and what I get from Metamask F.E.
However, for Zerion Wallet, the connection does not work at all, and the modal to accept the connection does not appear. For Spot Wallet, the connection does not work, and the modal to accept the connection appears with an "Authentication failed" error.
If you already have some wallets which are working on full flow with Kotlin XML (Even if with Compass), please share.
Which SDKs are you using in that example @Shitikyan ?? Is it a native kotlin app?
We are using Android SDK 13(Tiramisu) , and yes it is Kotlin app. Here are the versions of the Wallet Connect packages we are using: implementation("com.walletconnect:web3wallet:1.8.0") implementation("com.walletconnect:sign:2.13.0") implementation("com.walletconnect:android-core:1.15.0") implementation("com.walletconnect:android-bom:1.10.0")
We are using Android SDK 13(Tiramisu) , and yes it is Kotlin app. Here are the versions of the Wallet Connect packages we are using: implementation("com.walletconnect:web3wallet:1.8.0") implementation("com.walletconnect:sign:2.13.0") implementation("com.walletconnect:android-core:1.15.0") implementation("com.walletconnect:android-bom:1.10.0")
So how are you connecting to the wallet? with SignClient.connect()
method? As I'm trying in my code in the original question? Or using the Web3Modal? or which one?
For connecting to the wallet we are using SignClient.connect()
val connectParams = Sign.Params.Connect(namespaces, null, null, pairing)
SignClient.connect(connectParams,
onSuccess = { ->
viewModelScope.launch(Dispatchers.Main) {
onProposedSequence(pairing!!.uri)
}
},
onError = { error -> println(error.throwable.message) }
)
And for signing process SignClient.request() is used.
val requestParams = Sign.Params.Request(
sessionTopic = topic,
method = "personal_sign",
params = params,
chainId = "$parentChain:$chainId"
)
SignClient.request( requestParams, { }, { } )
SignClient.getActiveSessionByTopic(topic)?.redirect?.toUri()
?.let { deepLinkUri -> onProposedSequence(deepLinkUri) }
@Shitikyan I have been checking again and again, and I'm doing almost the same, instead of using the onproposedSequence I'm setting the uri into a viewmodel var (livedata) and opening the link. But still happening the same. Would be great if you could check my code (posted in the original question) very fast and see if you can point out my error, because apparently I have it as you and the example.
For the successful deep linking connection please follow this guide: https://docs.walletconnect.com/2.0/android/guides/mobile-linking Where you can find Dapp and Wallet sections
Dapp must send a correct uri deep link schema (described in docs) and wallet must register correct intent filter with correct schema to be able to receive a deep link from dapp
@jakubuid Is there a working version example? What I am using I took from Example
I read all the documentation and the example. Managed to test in some other devices, and my implementation is working with Trustwallet (it was correct, found something is happening with my test device). But still wallets not being able to process the requests.
I have found that there is an issue with the model Im using to test: Xiaomi Mi 10 T Lite (Android 12), tested with 3 other devices and its working.
@jakubuid Is it still on the calendar that everyone using v1 will stop working? There are a lot of wallets that haven't migrated or that the migration does not work properly (as you said you were working with them). TrustWallet is the only one I have managed to fully do what I need.
Yes, run our example dapp and wallet:
Tried to run the example, but after changing the projectId to mine, can't run because the app does not have the google-services.json file. Do you have any Readme about how to make it work?
I see, please use those distribution links to get apps:
I see, please use those distribution links to get apps:
Im sorry to say, with that app its happening the same as with my code referenced here: https://github.com/WalletConnect/WalletConnectKotlinV2/issues/899#issuecomment-1564063682
TrustWallet is working on other devices (as I said before something to happen with my test device), so Im having the same issues pointed in that comment except for Trustwallet that is working now.
I have no problem about this, just pending work to do, but my inquiries are about v1 sunset and what is happening with the wallets, because our users will have no option to work with. So, how can we solve the issue of v1 sunset without wallets working?
@idelburgo-iomob are you referring only to deep linking flow? Can you share your dapp where I can scan a QR code and test the connection with those wallets?
Regarding deep linking flow on native dapp - Trust works well which is already a huge user base - we work with BitKeep to improve it as well - deep linking flow on mobile browsers and a scanning qr code flow are also fine - so users should be able to connect to your dapp
@jakubuid I am using deep linking flow, as I have native app only, the QR is not a good option for me, because the user cant scan a QR with the device if the device is needed to read the QR. (The app is showing the QR and needs the same device to scan it)
Yes, run our example dapp and wallet:
Thank you for providing this example! This works with Trust Wallet, but does not work with the latest version of Metamask Android App. The Metamask wallet is one of the more popular wallets across our user base. Any help towards fixing this issue will be greatly appreciated.
@bujoralexandru Android MM is in the release process that supports WalletConnect v2 - we verified that the upcoming release works correctly- we had access to internal builds - the rollout of MM on Android is pretty slow but it's going on
@jakubuid Thank you so much for the fast response! So, I guess, testing with TrustWallet on Android should behave 1-on-1 like Metamask (after they release the correct version)?
I feel like it is a bit unsafe to sunset v1, while a major player in the crypto wallet market still hasn't got v2 right.
MM should reached 100% rollout by now - so it should be available for you as well - and yes the experience is the same
Thank you, @jakubuid - just to crosscheck, latest release on Android is May 24th, 2023, version 7.0.1?
@jakubuid Nice to hear! I tried my example application and the connect is working, but when sending the personal_sign it is opening Metamask and not appearing the modal to accept the signing. (This flow I have is working as it is for TrustWallet)
I also tried the app you sent me (WC Dapp) and its crashing when returning from accepting the connection to MetaMask :( Do you have any newer app in which you can do the process? Maybe this one is outdated?
Just to add more info: when sending the personal_sign (working in TrustWallet) it is returning instantly to my app to the onError
delegate with the following message:
Error(throwable=kotlinx.coroutines.TimeoutCancellationException: Timed out waiting for 300 ms)
Also giving me the following error on the onSessionRequestResponse
:
SessionRequestResponse(topic=4abc99af036b30cd5310b58042da3a0bc8225f2f1c22171159d41667e16e57e0, chainId=eip155:42220, method=personal_sign, result=JsonRpcError(id=1687332726651309, code=-32602, message=Invalid params))
Just to add: TrustWallet is also returning the timeout onError, but working the personal_sign.
This is the error happening in the app you shared:
Caused by: java.util.NoSuchElementException: Array contains no element matching the predicate.
at com.walletconnect.sample.dapp.ui.routes.composable_routes.session.SessionViewModel.getSessions(SessionViewModel.kt:1110)
at com.walletconnect.sample.dapp.ui.routes.composable_routes.session.SessionViewModel.getSessions$default(SessionViewModel.kt:44)
at com.walletconnect.sample.dapp.ui.routes.composable_routes.session.SessionViewModel.<init>(SessionViewModel.kt:21)
... 80 more
@jakubuid Can you please give timeline when auth integration will work? Tested it today with latest code for auth.requester and fresh trust wallet, still does not recognize as valid qr code (used deeplink)
@idelburgo-iomob Below there's a video showing a working example with Trust - the same result is for MM https://github.com/WalletConnect/WalletConnectKotlinV2/assets/23366251/efbe4576-6d70-40ad-b178-7d1554a46578
I'm not able to reproduce your errors - it seems that sth is wrong in your implementation - I'm happy to help but I need more details.
Caused by: java.util.NoSuchElementException: Array contains no element matching the predicate.
- this is sample dapp error - we'll investigate it but it's not related to the protocol itself
@Raenar4k the auth integration works on Trust via scanning QR code - there's indeed some problem on deeplinks, will report it to Trust
@jakubuid yes, as I said, I have no problem with Trust, just with MM. With TrustWallet I can make the same process you are showing. But not with MM.
If my implementation is working smoothly with Trust, shouldn't it be working the same with MM?
Plz, let me know if you solve the crash in the example app so I can test with MM. Is this app working with MM for you?
@jakubuid What you mean about more details? I can share with you whatever you need. I have my example app here in github. Its just a fragment+viewmodel with two buttons to connect and sign when it is connected.
As you can see on the video - MM works fine: https://github.com/WalletConnect/WalletConnectKotlinV2/assets/23366251/0e9b964b-84a3-4bf4-9f98-81ab9fa37a33
Plz, let me know if you solve the crash in the example app so I can test with MM. Is this app working with MM for you?
- please for now clear app's storage it should help
Can you share please your repo then? I'll have a look
After a fresh Install of your example Dapp and Metamask. It has worked!
But my app is giving the same error of Invalid params.
My code is in: https://github.com/idelburgo-iomob/walletConnectIntegrationExample it just connects with Celo right now. if you want to change the chain just set it in MainViewModel:146 @jakubuid
Let me know if you see something wrong. If you manage to know would be great as it is the only problem I have to finish the migration to v2.
the auth integration works on Trust via scanning QR code - there's indeed some problem on deeplinks, will report it to Trust
@jakubuid QR code scanning does not work for me either. This is fresh version from play store + fresh code from wallet connect repo:
@jakubuid is there a wallet that support auth.requester demo at this moment? Spot replies that QR code is not valid both on scan and deeplink, MM just does nothing.
@jakubuid
Below there's a video showing a working example with Trust - the same result is for MM
Can confirm that samples.dapp
is working for Spot and Trust wallet, both QR and deeplink! Nice. :)
(Auth.requester
does not sadly - still Not a WalletConnect valid QR code
)
@jakubuid Thx for your time and patience, managed to find my error.
When sending the parameters to the "personal_sign" method TrustWallet is accepting the account as:
"eip155:1:
The only problem I have is TrustWallet not working in some devices, at least in my test one, but works on the rest. So I assume is a problem with my specific model
Describe the bug While using WalletConnect v2, can't connect to a wallet supposedly migrated to v2 already. SDK Version
To Reproduce In an example app I created Steps to reproduce the behavior:
Expected behavior Wallet to open the modal and accept the connection to then sign a message. Tested with [example Wallet v2] (https://react-wallet.walletconnect.com/) and all the process works smoothly. Several wallets "migrated" to v2 does not open the modal to accept the connection they just open reacting to the deeplink, but keeps there without doing nothing
Screenshots If applicable, add screenshots to help explain your problem.
Device (please complete the following information):
Additional context I would like to know if I'm are the one doing something wrong or the wallets are not supporting really v2 as the example wallet https://react-wallet.walletconnect.com/ works without any flaw to connect and sign the message.
CODE used:
In the Application class
Where connecting