Skip to content
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

metamask wc deeplink #2038

Merged
merged 2 commits into from
Dec 2, 2020
Merged

metamask wc deeplink #2038

merged 2 commits into from
Dec 2, 2020

Conversation

estebanmino
Copy link
Contributor

Description

Using wallet connect recommending MetaMask wasn't working.

Checklist

  • There is a related GitHub issue
  • Tests are included if applicable
  • Any added code is fully documented

Issue

Resolves #???

@estebanmino estebanmino requested a review from a team as a code owner December 2, 2020 21:06
@estebanmino estebanmino merged commit 4d051b2 into develop Dec 2, 2020
@estebanmino estebanmino deleted the metamask-wc-deeplink branch December 2, 2020 21:22
@vonoro
Copy link

vonoro commented Jan 24, 2022

@estebanmino could you please advise me on how a url object can both

(1) have metamask in protocol field and at the same time
(2) have metamask://wc in origin field (added in this PR)?

https://github.com/MetaMask/metamask-mobile/pull/2038/files#diff-11a6eca2f0edf9a5f087e88e1ee68456686e8ef3c16466e41a5ddf3ee23e0a43R177

I might be stupid but it seems like in this case, the origin will always be null and so the condition is never true? See the test cases for origin in url-parse package https://github.com/unshiftio/url-parse/blob/f7774f608418b59a43ad1816c954654fdc8b1248/test/test.js#L433.

More generally, the PR is kind of vague, it'd be really nice if the PR included some details on how it can be tested 😢

Basically, what I'm trying to do is open metamask from an android dapp, and wire it up to my dapp using walletConnect, the same way that OpenSea does it. What is the right way to do this on android?
thanks so much :)

@github-actions
Copy link
Contributor

CLA Signature Action:

Thank you for your submission, we really appreciate it. We ask that you 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:

I have read the CLA Document and I hereby sign the CLA

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.

0 out of 1 committers have signed the CLA.
@estebanmino

@vonoro
Copy link

vonoro commented Jan 24, 2022

related: #3120

@vonoro
Copy link

vonoro commented Jan 25, 2022

in case anyone has the same problem, here's what I ended up using

        Intent launchIntent = getReactApplicationContext().getPackageManager().getLaunchIntentForPackage(packageId);
        if (launchIntent != null) {
          launchIntent.setData(Uri.parse(wcUri));
          getReactApplicationContext().startActivity(launchIntent);
        }

rickycodes pushed a commit that referenced this pull request Jan 31, 2022
* add wc in metamask dl

* rm logs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants