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

[Desktop] user funds do not move to Uphold - follow up to 8428 #11298

Closed
LaurenWags opened this issue Aug 18, 2020 · 5 comments · Fixed by brave/brave-core#6442
Closed

[Desktop] user funds do not move to Uphold - follow up to 8428 #11298

LaurenWags opened this issue Aug 18, 2020 · 5 comments · Fixed by brave/brave-core#6442

Comments

@LaurenWags
Copy link
Member

Description

Follow up to #8428 and brave/brave-core#6000

If you have anon user funds and you connect a KYC'd uphold wallet, the user funds do not move to Uphold.

Steps to Reproduce

Test plan 4 from brave/brave-core#6000

  • enable rewards
  • restore wallet with user funds
  • connect kyc uphold account
  • make sure that funds are transferred

Actual result:

Funds not moved. See below in the logs.

[ RESPONSE - OnTransferFunds ]
> Url: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/redacted/claim
> Result: Failure
> HTTP Code: 403
> Body: {"message":"error linking wallet: failed to verify transaction: failed to verify transaction","code":403}

Expected result:

funds should move

Reproduces how often:

easily

Brave version (brave://version info)

Brave 1.13.76 Chromium: 85.0.4183.69 (Official Build) dev (64-bit)
Revision 4554ea1a1171bd8d06951a4b7d9336afe6c59967-refs/branch-heads/4183@{#1426}
OS macOS Version 10.14.6 (Build 18G3020)

Version/Channel Information:

  • Can you reproduce this issue with the current release? n/a
  • Can you reproduce this issue with the beta channel? yes
  • Can you reproduce this issue with the nightly channel? yes

Other Additional Information:

  • Does the issue resolve itself when disabling Brave Shields?
  • Does the issue resolve itself when disabling Brave Rewards?
  • Is the issue reproducible on the latest version of Chrome?

Miscellaneous Information:

cc @NejcZdovc @rebron @brave/legacy_qa

@LaurenWags LaurenWags added feature/rewards priority/P2 A bad problem. We might uplift this to the next planned release. QA/Yes release-notes/exclude OS/Desktop labels Aug 18, 2020
@LaurenWags
Copy link
Member Author

I did not add OS/Android label as Android didn't have the ability for users to add their own funds. Please add label if this needs to be checked there as well. cc @srirambv

@GeetaSarvadnya
Copy link

Reproduced in Windows 10 x64 - 1.13.x Verified that ad grants are not moved to KYC'd uphold wallet

@LaurenWags
Copy link
Member Author

uplift approved, waiting on new 1.13.x build to test

@GeetaSarvadnya
Copy link

GeetaSarvadnya commented Aug 26, 2020

Verification is passed on


Brave | 1.13.80 Chromium: 85.0.4183.83 (Official Build) (64-bit)
-- | --
Revision | 94abc2237ae0c9a4cb5f035431c8adfb94324633-refs/branch-heads/4183@{#1658}
OS | Windows 10 OS Version 1903 (Build 18362.1016)

Scenario 1: - PASSED

  • Verified the STR from the description
  • Restored a wallet with user funds
    image
  • Verified wallet status is Not connected and Deposited balance is shown correctly in brave://rewards-internals
    image
  • Connected KYC'd uphold wallet and confirm funds are transferred to uphold card
    image
    image
  • Confirmed seeing the below in logs
[ REQUEST ]
> URL: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/redacted/claim
> Method: UrlMethod::POST
> Content: ..
[ RESPONSE - OnTransferFunds ]
> Url: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/redacted/claim
> Result: Success
> HTTP Code: 200

Scenario 2 - make sure that claim works with user funds and VG - PASSED

  • Clean profile, enable rewards. Restore a wallet with user funds and an Ad grant. Claim Ad grant
  • Ensured deposited BAT (5 BAT) and Rewards BAT (ad grants 20 BAT) is shown correctly in brave://rewards-internals
    image
    image
  • Connect KYC'd user wallet. Confirmed seeing the below in my logs:
[ REQUEST ]
> URL: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/4.../claim
> Method: UrlMethod::POST
[ RESPONSE - OnTransferFunds ]
> Url: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/4.../claim
> Result: Success
> HTTP Code: 200
[ REQUEST ]
> URL: https://grant.rewards.bravesoftware.com/v1/suggestions/claim
> Method: UrlMethod::POST
[ RESPONSE - OnRedeemTokens ]
> Url: https://grant.rewards.bravesoftware.com/v1/suggestions/claim
> Result: Success
> HTTP Code: 200
  • Confirmed all BAT (user funded and Ad grant) moved to Uphold:
    image

image
image

Scenario 3 - make sure that claim works with 0 balance - PASSED

  • Clean profile, enable rewards wallet balance is 0 BAT and wallet status is Not Connected
    image
    image

  • Connect KYC'd user wallet. Confirmed seeing the below in my logs:

[ REQUEST ]
> URL: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/1.../claim
> Method: UrlMethod::POST
[ RESPONSE - OnTransferFunds ]                                                                                                                                                               > Url: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/1.../claim           
> Result: Success                                                                                                                                                                            
> HTTP Code: 200

image
image


Verification PASSED on macOS 10.15.6 x64 using the following build:

Brave | 1.13.80 Chromium: 85.0.4183.83 (Official Build) (64-bit)
-- | --
Revision | 94abc2237ae0c9a4cb5f035431c8adfb94324633-refs/branch-heads/4183@{#1658}
OS | macOS Version 10.15.6 (Build 19G73)

Test Plan 1:

  • Checked Preferences and ensured that that the payment_id and seed values were populated via brave.rewards.wallet.

Test Plan 2:

  • ensured that you can restore several wallets using the Restore feature under Manage Your Wallet

Test Plan 3:

Screen Shot 2020-08-26 at 5 01 14 PM

Test Plan 4 - Scenario 1 (user funds):

Created & Restored a wallet that had user funds (10 BAT in this case). Example:

User Funded Wallet User Funded Wallet
Screen Shot 2020-08-26 at 10 33 58 PM Screen Shot 2020-08-26 at 10 34 18 PM

Connected to a KYC'd account and ensured the following:

[ REQUEST ]
> URL: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/[2a............]/claim
> Method: UrlMethod::POST
> Content:......
[ RESPONSE - OnTransferFunds ]
> Url: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/[2a............]/claim
> Result: Success
> HTTP Code: 200

Screen Shot 2020-08-26 at 10 44 03 PM

Test Plan 4 - Scenario 1 (user funds + VG):

Created & Restored a wallet that had user funds (10 BAT in this case) and claimed a VG. Example:

User Funded Wallet User Funded Wallet
Screen Shot 2020-08-26 at 10 49 18 PM Screen Shot 2020-08-26 at 10 49 26 PM

Connected to a KYC'd account and ensured the following:

[ REQUEST ]
> URL: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/[14.................]/claim
> Method: UrlMethod::POST
> Content:........
[ RESPONSE - OnTransferFunds ]
> Url: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/[14.................]/claim
> Result: Success
> HTTP Code: 200
[ REQUEST ]
> URL: https://grant.rewards.bravesoftware.com/v1/suggestions/claim
> Method: UrlMethod::POST
[ RESPONSE - OnRedeemTokens ]
> Url: https://grant.rewards.bravesoftware.com/v1/suggestions/claim
> Result: Success
> HTTP Code: 200

Screen Shot 2020-08-26 at 10 54 23 PM


Verification passed on

Brave 1.13.80 Chromium: 85.0.4183.83 (Official Build) (64-bit)
Revision 94abc2237ae0c9a4cb5f035431c8adfb94324633-refs/branch-heads/4183@{#1658}
OS Ubuntu 18.04 LTS

Verified test plan from brave/brave-core#6000

Test Plan 1:

  • Checked Preferences and ensured that that the payment_id and seed values were populated via brave.rewards.wallet.

Test Plan 2:

  • ensured that you can restore several wallets using the Restore feature under Manage Your Wallet

Test Plan 3:

image

Test Plan 4 - Scenario 1 (user funds):

Created & Restored a wallet that had user funds. Example:

image image

Connected to a KYC'd account and ensured the following:

[ RESPONSE - OnTransferFunds ]
> Url: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/[redacted]/claim
> Result: Success
> HTTP Code: 200

image

Test Plan 4 - Scenario 2 (user funds + VG):

Created & Restored a wallet that had user funds and claimed a VG. Example:

image image

Connected to a KYC'd account and ensured the following:

[ RESPONSE - OnTransferFunds ]
> Url: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/[redacted]/claim
> Result: Success
> HTTP Code: 200

[ RESPONSE - OnRedeemTokens ]
> Url: https://grant.rewards.bravesoftware.com/v1/suggestions/claim
> Result: Success
> HTTP Code: 200

image

@LaurenWags
Copy link
Member Author

Additional scenario verified (not listed in test plan from PR) using

Brave | 1.13.80 Chromium: 85.0.4183.83 (Official Build) (64-bit)
-- | --
Revision | 94abc2237ae0c9a4cb5f035431c8adfb94324633-refs/branch-heads/4183@{#1658}
OS | macOS Version 10.14.6 (Build 18G3020)

Confirmed claim process including getting KYC'd with Uphold.

  1. Claim an Ad grant on staging env:

claim ad grant

wallet balance

  1. Click Verify Wallet, follow prompts and provide all expected data to Uphold

  2. Contacted Uphold to get KYC completed

  3. Confirmed browser got KYC notice:

acct is KYCd

  1. Confirmed Ad grant moved to Uphold account:
[ REQUEST ]
> URL: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/........./claim
> Method: UrlMethod::POST
> Content: ........
[10503:775:0826/132157.823391:VERBOSE6:wallet_claim.cc(163)] 
[ RESPONSE - OnTransferFunds ]
> Url: https://grant.rewards.bravesoftware.com/v3/wallet/uphold/........./claim
> Result: Success
> HTTP Code: 200
> Body: null
[ REQUEST ]
> URL: https://grant.rewards.bravesoftware.com/v1/suggestions/claim
> Method: UrlMethod::POST
> Content: .........
[ RESPONSE - OnRedeemTokens ]
> Url: https://grant.rewards.bravesoftware.com/v1/suggestions/claim
> Result: Success
> HTTP Code: 200
> Body: 

acct is KYCd2

ad grant moves to uphold2

ad grant moves to uphold1

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

Successfully merging a pull request may close this issue.

5 participants