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

feat: account management wiring progression #6798

Merged
merged 6 commits into from
May 7, 2024

Conversation

woodenfurniture
Copy link
Contributor

@woodenfurniture woodenfurniture commented May 2, 2024

Description

Pull Request Type

  • 🐛 Bug fix (Non-breaking Change: Fixes an issue)
  • 🛠️ Chore (Non-breaking Change: Doc updates, pkg upgrades, typos, etc..)
  • 💅 New Feature (Breaking/Non-breaking Change)

Issue (if applicable)

closes #6789
closes #6788
closes #6797

Risk

High Risk PRs Require 2 approvals

Low risk.

What protocols, transaction types or contract interactions might be affected by this PR?

None of the above.

Testing

  • Check the account count on the manage accounts modal matches the number of accounts in the import accounts drawer. Note that it's very tricky to tell the difference between in inactive account and an active one if there is zero native asset balance on that account (see below for more info).

  • Check that all UXTO account types segwit native, segwit, legacy appear for a given account number

  • Check that native asset balances are loaded for accounts that are not auto-added (i.e there is an empty account in between 2 non-empty accounts - you can replicate this by adding 2 new accounts and transferring some coins into the second one - @MBMaria this is already set up on your native wallet for Ethereum). See below for more info.

Engineering

Operations

Screenshots (if applicable)

An ETH account may have some FOX but 0 ETH, so is active:
image
image

Similarly, a BTC account may have 0 BTC balance but non-zero thorchain savers balance:
image
image

Showing auto-detected accounts up to first empty one (it has 0ETH but has fox, so was detected. the second empty account is actually totally empty). The account after the 2 0ETH accounts has some eth, and the balance is loaded when viewed:

Screen.Recording.2024-05-04.at.10.30.28.AM.mov

@woodenfurniture woodenfurniture changed the base branch from develop to account-management-modal-4 May 2, 2024 04:14
@woodenfurniture woodenfurniture changed the title Account management wiring progression feat: account management wiring progression May 2, 2024
@woodenfurniture woodenfurniture force-pushed the account-management-modal-4 branch from 6d83dc0 to 831f5d8 Compare May 3, 2024 23:41
Base automatically changed from account-management-modal-4 to develop May 3, 2024 23:54
@woodenfurniture woodenfurniture force-pushed the account-management-modal-5 branch from 7e89360 to b77cd73 Compare May 4, 2024 00:03
@woodenfurniture woodenfurniture marked this pull request as ready for review May 4, 2024 00:35
@woodenfurniture woodenfurniture requested a review from a team as a code owner May 4, 2024 00:35
@0xApotheosis 0xApotheosis self-assigned this May 6, 2024
Copy link
Member

@0xApotheosis 0xApotheosis left a comment

Choose a reason for hiding this comment

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

First pass comments.

Copy link
Member

@0xApotheosis 0xApotheosis left a comment

Choose a reason for hiding this comment

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

Tested with Max's seed and confirmed that this does what it says it does.

Happy with this PR pending your thoughts on the comments above.

@gomesalexandre gomesalexandre self-requested a review May 6, 2024 07:29
Copy link
Contributor

@gomesalexandre gomesalexandre left a comment

Choose a reason for hiding this comment

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

Tested locally - a few smallish comments, but looks sane at runtime

Import Accounts count looks sane

Note for all of these, the 1*(script types) isn't necessarily true, currently, the accounts (wallet) page does not necessarily reflect it and may be missing accounts. This is a bug currently present on prod and has been captured in #6826.

  • Import Accounts count looks sane for BTC (3 script types per account number) ✅
image

Note the single scriptType for account 1 because of the issue stated above, unrelated to this PR

image image

Accounts per accout number are 3 as expected 🎉

  • Adding new accounts correctly add the 1*3 accounts for BTC ✅
image
  • Import Accounts count looks sane for DOGE (1 script type per account number) ✅
image image

The balance being 0 is correct - this account does have a 0-balance, all of its value being DeFi savers value.

  • Adding new accounts correctly add the 1*1 accounts for DOGE ✅
image
  • Import Accounts count looks sane for EVM chains (account-based = 1 account) ✅
image image
  • Adding new accounts correctly add the 1*1 accounts for EVM chains ✅
image
  • Import Accounts count looks sane for ATOM (account-based = 1 account) ✅

Minus the label issue noted during CR.

image image
  • Adding new accounts correctly add the 1*1 accounts for ATOM
image

Balances are working both for accounts already present, and those that are not yet imported ✅

image

@woodenfurniture woodenfurniture force-pushed the account-management-modal-5 branch from b77cd73 to c42909b Compare May 7, 2024 01:04
@woodenfurniture woodenfurniture merged commit 20f57fc into develop May 7, 2024
3 checks passed
@woodenfurniture woodenfurniture deleted the account-management-modal-5 branch May 7, 2024 01:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants