Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Warn users if provider does not support current location #102

Merged
merged 37 commits into from
Mar 12, 2021

Conversation

tarikbellamine
Copy link
Contributor

@tarikbellamine tarikbellamine commented Mar 9, 2021

Description

Using the MoonPay ipAddress endpoint, we are determining what country/state a user is currently located. Using that location, we conditionally render a warning on each provider on the ProviderOptionsScreen rather than hide providers that may not be accessible.

To Do: Update the restricted country list for each provider

Other changes

N/A

Tested

Yes

Related issues

Backwards compatibility

Yes

simulator_screenshot_DAA0BF20-26F0-4D68-9425-3B1185721EFF

Copy link
Contributor

@gnardini gnardini left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This feels like a much better solution than what we had before 🙌

Left a couple small comments 😄

Copy link
Contributor

@gnardini gnardini left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! 😄

Copy link
Member

@jeanregisser jeanregisser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work! 👍
Left some small comments

Base automatically changed from tarikbellamine/cico-provider-keys to main March 11, 2021 08:28
@tarikbellamine tarikbellamine requested a review from i1skn as a code owner March 11, 2021 08:28
@tarikbellamine tarikbellamine removed the request for review from i1skn March 11, 2021 19:45
Copy link
Member

@jeanregisser jeanregisser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@tarikbellamine tarikbellamine added the automerge Have PR merge automatically when checks pass label Mar 12, 2021
@tarikbellamine tarikbellamine merged commit 6e1b904 into main Mar 12, 2021
@tarikbellamine tarikbellamine deleted the tarikbellamine/cico-region-limits branch March 12, 2021 20:59
@ValoraQA
Copy link

ValoraQA commented Mar 23, 2021

Hi jean , gn I have verified this issue using latest latest Android Internal Build V1.12.0(1004294340) & Test flight build V1.12.0(49) & observed following:
Observations:

  • For iOS:

  • For US country: US user able to see Moonpay, Ramp, links. But user gets popup saying this allows app & website to share information about you when user taps on both links.

  • Also it observed that user not get any popup to US user for "Transak" link & user able to proceed for provider.

  • Observed same as above two points for user who logged in without phone number & also for Germany country user.

  • For Android:

  • US user not able to get any popup regrading share information & user proceeds when taps on all three links. i.e. Moonpay, Ramp, Transak & for only Moonpay user get "transaction limit exceeded message".

  • Observed same as above two points for user who logged in without phone number & also for Germany country user. Let me know is this expected?
    Attachments:
    ShareInfoPopupForiOS.png
    NoAnyPopupForAndroid.mp4

Verified on devices: Samsung Galaxy A5(7.0), iPhone XR (14.2)

Let me know needful for above points .
Also let me know if anything need to test.

Thanks..!!

@i1skn
Copy link
Contributor

i1skn commented Mar 23, 2021

cc: @tarikbellamine

@tarikbellamine
Copy link
Contributor Author

Hi @Celoqa! The important thing to test here is if the grey text in the screenshot ("Limited support in region") is shown where appropriate. The list of which options should show "limited support in region" is available here: https://github.com/celo-org/wallet/blob/main/packages/mobile/src/flags.ts#L54

For example, the text should appear for Moonpay if the user is in the US. It should not appear for Ramp if the user is in France.

@ValoraQA
Copy link

Hey @tarikbellamine I have re-verified this issue using Android Internal Build V1.12.0(1004294340) & Test flight build V1.12.0(49) & observed following.
Observations:

  • We have verified max countries but we not able; to see "Limited support in region" text below respective restricted providers.
  • Also we have not observed text for all Moonpay , Ramp, Simplex, Transak links.
    Attachment: NoAnyTextBelowRestricatedProviders.mp4

Verified on devices: Samsung Galaxy A5(7.0), iPhone XR (14.2)

@tarikbellamine
Copy link
Contributor Author

This is difficult to test because we determine location based off of IP address. You will need a VPN to connect through a restricted country in order to test. I think you can skip this for now but we should revisit how to best test this functionality.

@ValoraQA
Copy link

HI @tarik here we have tested this task by using Tunnel bear VPN app and observed some countries are shown warm messages with grey text.

Able to see Grey text on Moonpay when user is on below given countries

  • United states [Limited support in region]

Able to see Grey text on Ramp when user is on below given countries

  • Argentina [Limited support in region]
  • Colombia[Limited support in region]
  • Japan[Limited support in region]

Able to see Grey text on Transak when user is on below given countries

  • UK [Limited support in region]
  • Moldava [Limited support in region]

Note: We have only some countries which are available in Tunnel bear So, we have tested countries which are available in Tunnel bear for now. Can you please let us know if you want to cover any specific country, We can try to cover.
Thanks!

@tarikbellamine
Copy link
Contributor Author

This is good, thank you!

@ValoraQA
Copy link

Always a pleasure @tarikbellamine

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
automerge Have PR merge automatically when checks pass
Projects
None yet
5 participants