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

Move ledger database to ledger native library #6363

Closed
tmancey opened this issue Oct 8, 2019 · 3 comments · Fixed by brave/brave-core#4252
Closed

Move ledger database to ledger native library #6363

tmancey opened this issue Oct 8, 2019 · 3 comments · Fixed by brave/brave-core#4252

Comments

@tmancey
Copy link
Contributor

tmancey commented Oct 8, 2019

Move ledger database to ledger native library so that schema changes are no longer required on the client

@tmancey tmancey self-assigned this Oct 8, 2019
@tmancey tmancey added dev-concern priority/P2 A bad problem. We might uplift this to the next planned release. labels Oct 8, 2019
@NejcZdovc
Copy link
Contributor

big ++ on this one

@NejcZdovc NejcZdovc assigned NejcZdovc and unassigned tmancey Nov 11, 2019
@masparrow
Copy link

Nb. When brave/brave-core#4035 is merged, we should look at Promotion / HandleExpiredPromotions to see if it can/should become a query instead of code.

@LaurenWags
Copy link
Member

LaurenWags commented Apr 1, 2020

Verified the below using a mix of 1.7.79 and

Brave 1.7.81 Chromium: 80.0.3987.149 (Official Build) dev (64-bit)
Revision 5f4eb224680e5d7dca88504586e9fd951840cac6-refs/branch-heads/3987_137@{#16}
OS macOS Version 10.14.6 (Build 18G3020)

Clean profile (anon wallet):

  • Verified able to create a new wallet (join Rewards from panel)
  • Verified able to create a new wallet (join Rewards from brave://rewards page)
  • Verified when Rewards are enabled from panel or brave://rewards, Ads are enabled by default if in an Ads region.
  • Verified able to restore a wallet.
  • Verified account balance shows correct BAT and USD value.
  • Verified able to successfully claim a UGP grant on staging env.
  • Verified able to successfully claim an ad grant on staging env.
  • Verified actions taken (claiming grant, tipping, auto-contribute) display in wallet panel.
  • Verified AC monthly budget shows correct BAT and USD value.
  • Verified able to exclude a publisher from the auto-contribute table by clicking on the x in auto-contribute table and popup list of sites.
  • Verified able to exclude a publisher by using the toggle on the Rewards Panel.
  • Verified able to perform an auto contribution.
  • Verified BR panel shows message about an unverified publisher.
  • Verified tip panel shows a message about unverified publisher.
  • Verified BR panel shows a verified checkmark for a verified creator.
  • Verified tip panel shows a verified checkmark for a verified creator.
  • Verified when clicking on Send a tip, the custom tip banner displays if set up.
  • Verified able to make one-time tip and it displays in Tips panel.
  • Verified able to make recurring tip and it displays in Monthly Contributions panel.
    • Verified able to adjust recurring tip amount from the BR panel.
    • Verified able to delete recurring tip from brave://rewards page or panel.
  • Verified able to tip a verified website.
    • Verified the website displays in the auto-contribute list after specified amount of time/visits per settings.
  • Verified able to tip a verified YouTube creator.
    • Verified the YouTube creator displays in the auto-contribute list after specified amount of time/visits per settings.
  • Verified able to tip a verified Vimeo creator.
    • Verified the Vimeo creator displays in the auto-contribute list after specified amount of time/visits per settings.
  • Verified able to tip a verified Twitch creator.
  • Verified able to tip a verified Twitter user from the panel.
  • Verified able to tip a verified Twitter user via inline tip button.
    • Verified the in-line tip button is spaced properly (checked when logged in and not logged in to Twitter).
  • Verified able to tip a verified Github user from the panel.
  • Verified able to tip a verified Github user via inline tip button.
    • Verified the Github creator displays in the auto-contribute list after specified amount of time/visits per settings.
  • Verified able to tip a verified Reddit user from the panel.
  • Verified able to tip a verified Reddit user via inline tip button.
  • Verified if you disable auto-contribute you are still able to tip creators.
  • Verified if auto-contribute is disabled AC does not occur.
  • Verified if AC is disabled but you have monthly contributions set up, recurring tips(monthly contributions) are contributed and AC does not occur.
  • Verified if Rewards is disabled AC does not occur.
  • Verified that disabling Rewards and enabling it again does not lose state.
  • Verified that disabling auto-contribute and enabling it again does not lose state.
  • Verified when I adjust min visit/time in settings. Visited some sites to verify they are added to the table after the specified settings.

Clean profile KYC'd user wallet

  • Verified able to connect a KYC'd Uphold wallet to Rewards.
    • Verified if you have Brave controlled funds (ex. UGP grant), you can tip both connected and KYC'd creators.
    • Verified wallet balance in Brave updates when BAT is added to the Brave Browser card.
    • [FAIL - see issues list below] Unable to verify if you only have user controlled BAT (BAT in Uphold only), you can only tip KYC'd creators, any tips to non-KYC'd creators go to the Pending Contributions list.
    • Verified able to AC
    • Verified able to contribute monthly tips

Upgrade case 1: Install 1.0. Set up as all data you can (some data cannot be set up on 1.0) and connect a KYC'd uphold wallet. Update to 1.7.x.

  • Verified the wallet balance is retained and wallet backup code isn't corrupted.
  • Verified auto-contribute list is not lost after upgrade.
  • Verified tips list is not lost after upgrade.
  • Verified wallet panel transactions list is not lost after upgrade.
  • Verified still able to tip and have AC go thru after upgrade.
  • Verified if I repeat the above case but using a restored anon wallet, all works as expected.

Upgrade case 2: Install current Release version (1.5.115 at this moment). Set up data (Ads panel, AC list, one time and recurring tips, wallet balance, wallet summary items, etc) and connect a KYC'd uphold wallet. Update to 1.7.x

  • Verified when updating from above version Ads info in the panel is not lost.
  • Verified the wallet balance is retained and wallet backup code isn't corrupted.
  • Verified auto-contribute list is not lost after upgrade.
  • Verified tips list is not lost after upgrade.
  • Verified wallet panel transactions list is not lost after upgrade.
  • Verified still able to tip and have AC go thru after upgrade.

Upgrade Case 3: Install current Release version (1.5.115 at this moment). Disable AC via toggle.

  • Verified after updating to 1.7.x build auto-contribute is still disabled after upgrade.
  • Verified Ads and Rewards are still toggled on.

Upgrade Case 4: Install current Release version (1.5.115 at this moment). Disable Ads via toggle.

  • Verified after updating to 1.7.x build Ads is still disabled after upgrade.
  • Verified AC and Rewards are still toggled on.

Upgrade Case 5: Install current Release version (1.5.115 at this moment). Enable then disable Rewards via toggle.

  • Verified after updating to PR build Rewards is still disabled after upgrade.

Encountered the following issues while testing:

Verification passed on

Brave 1.7.85 Chromium: 80.0.3987.162 (Official Build) dev (64-bit)
Revision f2c5dd6138153bb0658091205bd1a1717f16081a-refs/branch-heads/3987@{#1034}
OS Windows 10 OS Version 1803 (Build 17134.1006)

Clean profile (anon wallet):

  • Verified able to create a new wallet (join Rewards from panel)
  • Verified able to create a new wallet (join Rewards from brave://rewards page)
  • Verified when Rewards are enabled from panel or brave://rewards, Ads are enabled by default if in an Ads region.
  • Verified able to restore a wallet.
  • Verified account balance shows correct BAT and USD value.
  • Verified able to successfully claim a UGP grant on staging env.
  • Verified able to successfully claim an ad grant on staging env.
  • Verified actions taken (claiming grant, tipping, auto-contribute) display in wallet panel.
  • Verified AC monthly budget shows correct BAT and USD value.
  • Verified able to exclude a publisher from the auto-contribute table by clicking on the x in auto-contribute table and popup list of sites.
  • Verified able to exclude a publisher by using the toggle on the Rewards Panel.
  • Verified able to perform an auto contribution.
  • Verified BR panel shows message about an unverified publisher.
  • Verified tip panel shows a message about unverified publisher.
  • Verified BR panel shows a verified checkmark for a verified creator.
  • Verified tip panel shows a verified checkmark for a verified creator.
  • Verified when clicking on Send a tip, the custom tip banner displays if set up.
  • Verified able to make one-time tip and it displays in Tips panel.
  • Verified able to make recurring tip and it displays in Monthly Contributions panel.
    • Verified able to adjust recurring tip amount from the BR panel.
    • Verified able to delete recurring tip from brave://rewards page or panel.
  • Verified able to tip a verified website.
    • Verified the website displays in the auto-contribute list after specified amount of time/visits per settings.
  • Verified able to tip a verified YouTube creator.
    • Verified the YouTube creator displays in the auto-contribute list after specified amount of time/visits per settings.
  • Verified able to tip a verified Vimeo creator.
    • Verified the Vimeo creator displays in the auto-contribute list after specified amount of time/visits per settings.
  • Verified able to tip a verified Twitch creator.
  • Verified able to tip a verified Twitter user from the panel.
  • Verified able to tip a verified Twitter user via inline tip button.
    • Verified the in-line tip button is spaced properly (checked when logged in and not logged in to Twitter).
  • Verified able to tip a verified Github user from the panel.
  • Verified able to tip a verified Github user via inline tip button.
    • Verified the Github creator displays in the auto-contribute list after specified amount of time/visits per settings.
  • Verified able to tip a verified Reddit user from the panel.
  • Verified able to tip a verified Reddit user via inline tip button.
  • Verified if you disable auto-contribute you are still able to tip creators.
  • Verified if auto-contribute is disabled AC does not occur.
  • Verified if AC is disabled but you have monthly contributions set up, recurring tips(monthly contributions) are contributed and AC does not occur.
  • Verified if Rewards is disabled AC does not occur.
  • Verified that disabling Rewards and enabling it again does not lose state.
  • Verified that disabling auto-contribute and enabling it again does not lose state.
  • Verified when I adjust min visit/time in settings. Visited some sites to verify they are added to the table after the specified settings.

Clean profile KYC'd user wallet

  • Verified able to connect a KYC'd Uphold wallet to Rewards.
    • Verified if you have Brave controlled funds (ex. UGP grant), you can tip both connected and KYC'd creators.
    • Verified wallet balance in Brave updates when BAT is added to the Brave Browser card.
    • [FAIL - see issues list below] Unable to verify if you only have user controlled BAT (BAT in Uphold only), you can only tip KYC'd creators, any tips to non-KYC'd creators go to the Pending Contributions list.
    • Verified able to AC
    • Verified able to contribute monthly tips

Upgrade case 1: Install 1.0. Set up as all data you can (some data cannot be set up on 1.0) and connect a KYC'd uphold wallet. Update to 1.7.x.

  • Verified the wallet balance is retained and wallet backup code isn't corrupted.
  • Verified auto-contribute list is not lost after upgrade.
  • Verified tips list is not lost after upgrade.
  • Verified wallet panel transactions list is not lost after upgrade.
  • Verified still able to tip and have AC go thru after upgrade.
  • Verified if I repeat the above case but using a restored anon wallet, all works as expected.

Upgrade case 2: Install current Release version (1.5.115 at this moment). Set up data (Ads panel, AC list, one time and recurring tips, wallet balance, wallet summary items, etc) and connect a KYC'd uphold wallet. Update to 1.7.x

  • Verified when updating from above version Ads info in the panel is not lost.
  • Verified the wallet balance is retained and wallet backup code isn't corrupted.
  • Verified auto-contribute list is not lost after upgrade.
  • Verified tips list is not lost after upgrade.
  • Verified wallet panel transactions list is not lost after upgrade.
  • Verified still able to tip and have AC go thru after upgrade.

Upgrade Case 3: Install current Release version (1.5.115 at this moment). Disable AC via toggle.

  • Verified after updating to 1.7.x build auto-contribute is still disabled after upgrade.
  • Verified Ads and Rewards are still toggled on.

Upgrade Case 4: Install current Release version (1.5.115 at this moment). Disable Ads via toggle.

  • Verified after updating to 1.7.x build Ads is still disabled after upgrade.
  • Verified AC and Rewards are still toggled on.

Upgrade Case 5: Install current Release version (1.5.115 at this moment). Enable then disable Rewards via toggle.

  • Verified after updating to PR build Rewards is still disabled after upgrade.

Encountered the following issues while testing:

Verification passed on

Brave 1.7.86 Chromium: 80.0.3987.163 (Official Build) (64-bit)
Revision e7fbe071abe9328cdce4ffedac9822435fbd3656-refs/branch-heads/3987@{#1037}
OS Ubuntu 18.04 LTS

Clean profile (anon wallet):

  • Verified able to create a new wallet (join Rewards from panel)
  • Verified able to create a new wallet (join Rewards from brave://rewards page)
  • Verified when Rewards are enabled from panel or brave://rewards, Ads are enabled by default if in an Ads region.
  • Verified able to restore a wallet.
  • Verified account balance shows correct BAT and USD value.
  • Verified able to successfully claim a UGP grant on staging env.
  • Verified able to successfully claim an ad grant on staging env.
  • Verified actions taken (claiming grant, tipping, auto-contribute) display in wallet panel.
  • Verified AC monthly budget shows correct BAT and USD value.
  • Verified able to exclude a publisher from the auto-contribute table by clicking on the x in auto-contribute table and popup list of sites.
  • Verified able to exclude a publisher by using the toggle on the Rewards Panel.
  • Verified able to perform an auto contribution.
  • Verified BR panel shows message about an unverified publisher.
  • Verified tip panel shows a message about unverified publisher.
  • Verified BR panel shows a verified checkmark for a verified creator.
  • Verified tip panel shows a verified checkmark for a verified creator.
  • Verified when clicking on Send a tip, the custom tip banner displays if set up.
  • Verified able to make one-time tip and it displays in Tips panel.
  • Verified able to make recurring tip and it displays in Monthly Contributions panel.
    • Verified able to adjust recurring tip amount from the BR panel.
    • Verified able to delete recurring tip from brave://rewards page or panel.
  • Verified able to tip a verified website.
    • Verified the website displays in the auto-contribute list after specified amount of time/visits per settings.
  • Verified able to tip a verified YouTube creator.
    • Verified the YouTube creator displays in the auto-contribute list after specified amount of time/visits per settings.
  • Verified able to tip a verified Vimeo creator.
    • Verified the Vimeo creator displays in the auto-contribute list after specified amount of time/visits per settings.
  • Verified able to tip a verified Twitch creator.
  • Verified able to tip a verified Twitter user from the panel.
  • Verified able to tip a verified Twitter user via inline tip button.
    • Verified the in-line tip button is spaced properly (checked when logged in and not logged in to Twitter).
  • Verified able to tip a verified Github user from the panel.
  • Verified able to tip a verified Github user via inline tip button.
    • Verified the Github creator displays in the auto-contribute list after specified amount of time/visits per settings.
  • Verified able to tip a verified Reddit user from the panel.
  • Verified able to tip a verified Reddit user via inline tip button.
  • Verified if you disable auto-contribute you are still able to tip creators.
  • Verified if auto-contribute is disabled AC does not occur.
  • Verified if AC is disabled but you have monthly contributions set up, recurring tips(monthly contributions) are contributed and AC does not occur.
  • Verified if Rewards is disabled AC does not occur.
  • Verified that disabling Rewards and enabling it again does not lose state.
  • Verified that disabling auto-contribute and enabling it again does not lose state.
  • Verified when I adjust min visit/time in settings. Visited some sites to verify they are added to the table after the specified settings.

Clean profile KYC'd user wallet

  • Verified able to connect a KYC'd Uphold wallet to Rewards.
    • Verified if you have Brave controlled funds (ex. UGP grant), you can tip both connected and KYC'd creators.
    • Verified wallet balance in Brave updates when BAT is added to the Brave Browser card.
    • [FAIL - see issues list below] Unable to verify if you only have user controlled BAT (BAT in Uphold only), you can only tip KYC'd creators, any tips to non-KYC'd creators go to the Pending Contributions list.
    • Verified able to AC
    • Verified able to contribute monthly tips

Upgrade case 1: Install 1.0. Set up as all data you can (some data cannot be set up on 1.0) and connect a KYC'd uphold wallet. Update to 1.7.x.

  • Verified the wallet balance is retained and wallet backup code isn't corrupted.
  • Verified auto-contribute list is not lost after upgrade.
  • Verified tips list is not lost after upgrade.
  • Verified wallet panel transactions list is not lost after upgrade.
  • Verified still able to tip and have AC go thru after upgrade.
  • Verified if I repeat the above case but using a restored anon wallet, all works as expected.

Upgrade case 2: Install current Release version (1.5.115 at this moment). Set up data (Ads panel, AC list, one time and recurring tips, wallet balance, wallet summary items, etc) and connect a KYC'd uphold wallet. Update to 1.7.x

  • Verified when updating from above version Ads info in the panel is not lost.
  • Verified the wallet balance is retained and wallet backup code isn't corrupted.
  • Verified auto-contribute list is not lost after upgrade.
  • Verified tips list is not lost after upgrade.
  • Verified wallet panel transactions list is not lost after upgrade.
  • Verified still able to tip and have AC go thru after upgrade.

Upgrade Case 3: Install current Release version (1.5.115 at this moment). Disable AC via toggle.

  • Verified after updating to 1.7.x build auto-contribute is still disabled after upgrade.
  • Verified Ads and Rewards are still toggled on.

Upgrade Case 4: Install current Release version (1.5.115 at this moment). Disable Ads via toggle.

  • Verified after updating to 1.7.x build Ads is still disabled after upgrade.
  • Verified AC and Rewards are still toggled on.

Upgrade Case 5: Install current Release version (1.5.115 at this moment). Enable then disable Rewards via toggle.

  • Verified after updating to PR build Rewards is still disabled after upgrade.

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.

6 participants