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

fix(cherry-pick): remove BTC accounts from send flow (#26271) #26821

Merged

Conversation

ccharly
Copy link
Contributor

@ccharly ccharly commented Aug 30, 2024

Description

This PR cherry-picks the commit fbd1ea1 into the RC v12.2.0

Open in GitHub Codespaces

Related issues

Fixes: NA

Manual testing steps

Refer to #26271

Screenshots/Recordings

Refer to #26271

Pre-merge author checklist

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

ccharly and others added 4 commits August 30, 2024 17:16
Adds support of testnet account within the extension following the same
pattern than for mainnet accounts with a feature flag.

[![Open in GitHub
Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/25772?quickstart=1)

Fixes: **MetaMask/accounts-planning#511

1. Run `yarn start:flask`
2. Go to the experimental settings tab
3. Enable the "Bitcoin testnet support" toggle
4. Click on the account menu list (on top)
5. You should now see a "Add a new Bitcoin account (Testnet)"
6. Click this button and follow the flow
7. You should now see a testnet account (starting with `tb1q...`)

https://github.com/MetaMask/metamask-extension/assets/569258/b59b9fc5-dc85-4b5f-87be-38e42256b243

- [x] I've followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask
Extension Coding
Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md).
- [x] I've completed the PR template to the best of my ability
- [x] I’ve included tests if applicable
- [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [x] I’ve applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

- [ ] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [ ] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.

---------

Co-authored-by: Daniel Rocha <[email protected]>
This state has been moved from the initial file, so we had to report it
back in the new file, otherwise tests will diff and fail.
<!--
Please submit this PR as a draft initially.
Do not mark it as "Ready for review" until the template has been
completely filled out, and PR status checks have passed at least once.
-->

<!--
Write a short description of the changes included in this pull request,
also include relevant motivation and context. Have in mind the following
questions:
1. What is the reason for the change?
2. What is the improvement/solution?
-->

This PR removes BTC accounts from the account picker and `Your Accounts`
list in the send flow.

[![Open in GitHub
Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/26271?quickstart=1)

Fixes: MetaMask/accounts-planning#546

1. Create btc account
2. Select an evm account
3. Click send
4. See that the BTC account is not available in `Your Accounts`
5. Click the account picker and see that the BTC account is not
available.

<!-- If applicable, add screenshots and/or recordings to visualize the
before and after of your change. -->

<!-- [screenshots/recordings] -->
![Screenshot 2024-08-01 at 15 01
15](https://github.com/user-attachments/assets/42ab54eb-f97f-46d4-9179-8bc7d6a84fe1)
![Screenshot 2024-08-01 at 15 01
18](https://github.com/user-attachments/assets/e74b0d1a-3192-4831-a3cd-ccefe3e0c74f)

<!-- [screenshots/recordings] -->
![Screenshot 2024-08-01 at 14 58
39](https://github.com/user-attachments/assets/ba4b3136-766c-4222-afe4-ecbc455cb37c)
![Screenshot 2024-08-01 at 14 58
43](https://github.com/user-attachments/assets/6d9bef5b-68a9-4eee-9a11-672788855000)

- [x] I've followed [MetaMask Contributor
Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask
Extension Coding
Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md).
- [x] I've completed the PR template to the best of my ability
- [x] I’ve included tests if applicable
- [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format
if applicable
- [x] I’ve applied the right labels on the PR (see [labeling
guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)).
Not required for external contributors.

- [ ] I've manually tested the PR (e.g. pull and build branch, run the
app, test code being changed).
- [ ] I confirm that this PR addresses all acceptance criteria described
in the ticket it closes and includes the necessary testing evidence such
as recordings and or screenshots.

---------

Co-authored-by: Charly Chevalier <[email protected]>
Copy link
Contributor

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@gantunesr gantunesr changed the title V12.2.0 cherrypick remove btc accounts from send page fix(cherry-pick): remove the ability to send to BTC accounts in send page (fbd1ea1) Aug 30, 2024
@gantunesr gantunesr changed the title fix(cherry-pick): remove the ability to send to BTC accounts in send page (fbd1ea1) fix(cherry-pick): remove the ability to send to BTC accounts in send page (#26271) Aug 30, 2024
@gantunesr gantunesr changed the title fix(cherry-pick): remove the ability to send to BTC accounts in send page (#26271) fix(cherry-pick): remove BTC accounts from send flow (#26271) Aug 30, 2024
@gantunesr gantunesr marked this pull request as ready for review August 30, 2024 21:10
@gantunesr gantunesr requested a review from a team as a code owner August 30, 2024 21:10
Copy link
Contributor

@owencraston owencraston left a comment

Choose a reason for hiding this comment

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

Confirmed behaviour is as expected.

Screenshot 2024-08-30 at 2 24 57 PM Screenshot 2024-08-30 at 2 25 03 PM

@metamaskbot
Copy link
Collaborator

Builds ready [5fad458]
Page Load Metrics (419 ± 332 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint89153109178
domContentLoaded97129178
load471981419691332
domInteractive97129178

Copy link

codecov bot commented Sep 2, 2024

Codecov Report

Attention: Patch coverage is 87.50000% with 4 lines in your changes missing coverage. Please review.

Project coverage is 70.41%. Comparing base (d4a3c91) to head (5fad458).

Files with missing lines Patch % Lines
...multichain/account-list-menu/account-list-menu.tsx 84.00% 4 Missing ⚠️
Additional details and impacted files
@@                 Coverage Diff                 @@
##           Version-v12.2.0   #26821      +/-   ##
===================================================
+ Coverage            70.40%   70.41%   +0.01%     
===================================================
  Files                 1399     1399              
  Lines                49457    49471      +14     
  Branches             13587    13589       +2     
===================================================
+ Hits                 34817    34833      +16     
+ Misses               14640    14638       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ccharly ccharly merged commit d91ea1d into Version-v12.2.0 Sep 2, 2024
66 checks passed
@ccharly ccharly deleted the v12.2.0-cherrypick-remove-btc-accounts-from-send-page branch September 2, 2024 10:20
@github-actions github-actions bot locked and limited conversation to collaborators Sep 2, 2024
@metamaskbot metamaskbot added the release-12.2.0 Issue or pull request that will be included in release 12.2.0 label Sep 2, 2024
@metamaskbot
Copy link
Collaborator

No release label on PR. Adding release label release-12.2.0 on PR, as PR was cherry-picked in branch 12.2.0.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
release-12.2.0 Issue or pull request that will be included in release 12.2.0 team-accounts
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants