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

refactor: remove global network usage from transaction confirmations #12955

Merged
merged 15 commits into from
Jan 24, 2025

Conversation

matthewwalsh0
Copy link
Member

@matthewwalsh0 matthewwalsh0 commented Jan 13, 2025

Description

Remove all global network references from the transaction confirmations and confirmations in general.

Note that some exceptions remain in the send components as these transactions are triggered internally so cannot rely on a dApp selected network.

Specifically:

  • Add component properties:
    • AddressElement > chainId
    • AddressList > chainId
    • SendFlowAddressFrom > chainId
  • Add selectors:
    • selectConversionRateByChainId
    • selectProviderTypeByChainId
    • selectRpcUrlByChainId
    • selectContractExchangeRatesByChainId
  • Update linting rule to apply to entire app/components/Views/confirmations directory.

Related issues

Fixes: #2025

Manual testing steps

Screenshots/Recordings

Before

After

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.

@matthewwalsh0 matthewwalsh0 added the team-confirmations Push issues to confirmations team label Jan 13, 2025
@matthewwalsh0 matthewwalsh0 added the Run Smoke E2E Triggers smoke e2e on Bitrise label Jan 13, 2025
Copy link
Contributor

github-actions bot commented Jan 13, 2025

https://bitrise.io/ Bitrise

❌❌❌ pr_smoke_e2e_pipeline failed on Bitrise! ❌❌❌

Commit hash: a02277f
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/ce8ca728-42de-4f5f-be81-564bb46c79b4

Note

  • You can kick off another pr_smoke_e2e_pipeline on Bitrise by removing and re-applying the Run Smoke E2E label on the pull request

Tip

  • Check the documentation if you have any doubts on how to understand the failure on bitrise

@matthewwalsh0 matthewwalsh0 added Run Smoke E2E Triggers smoke e2e on Bitrise and removed Run Smoke E2E Triggers smoke e2e on Bitrise labels Jan 13, 2025
@matthewwalsh0 matthewwalsh0 added Run Smoke E2E Triggers smoke e2e on Bitrise and removed Run Smoke E2E Triggers smoke e2e on Bitrise labels Jan 13, 2025
Copy link
Contributor

github-actions bot commented Jan 13, 2025

https://bitrise.io/ Bitrise

❌❌❌ pr_smoke_e2e_pipeline failed on Bitrise! ❌❌❌

Commit hash: 9f6436d
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/330a40a2-3bc3-4cd2-8dcc-a213b00e6769

Note

  • You can kick off another pr_smoke_e2e_pipeline on Bitrise by removing and re-applying the Run Smoke E2E label on the pull request

Tip

  • Check the documentation if you have any doubts on how to understand the failure on bitrise

@matthewwalsh0 matthewwalsh0 added Run Smoke E2E Triggers smoke e2e on Bitrise and removed Run Smoke E2E Triggers smoke e2e on Bitrise labels Jan 13, 2025
@matthewwalsh0 matthewwalsh0 added Run Smoke E2E Triggers smoke e2e on Bitrise and removed Run Smoke E2E Triggers smoke e2e on Bitrise labels Jan 14, 2025
Copy link
Contributor

github-actions bot commented Jan 14, 2025

https://bitrise.io/ Bitrise

✅✅✅ pr_smoke_e2e_pipeline passed on Bitrise! ✅✅✅

Commit hash: c5f31a3
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/f0ca795c-c66b-407f-8a8b-83942968cc03

Note

  • You can kick off another pr_smoke_e2e_pipeline on Bitrise by removing and re-applying the Run Smoke E2E label on the pull request

@codecov-commenter
Copy link

codecov-commenter commented Jan 14, 2025

Codecov Report

Attention: Patch coverage is 81.25000% with 21 lines in your changes missing coverage. Please review.

Project coverage is 60.01%. Comparing base (faf5340) to head (ca78031).
Report is 35 commits behind head on main.

Files with missing lines Patch % Lines
...imulation/components/ValueDisplay/ValueDisplay.tsx 54.28% 6 Missing and 10 partials ⚠️
app/components/Views/confirmations/Send/index.js 62.50% 3 Missing ⚠️
app/components/Views/Settings/Contacts/index.js 0.00% 1 Missing ⚠️
...nents/Views/confirmations/SendFlow/SendTo/index.js 91.66% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #12955      +/-   ##
==========================================
+ Coverage   59.83%   60.01%   +0.18%     
==========================================
  Files        1873     1900      +27     
  Lines       42121    42557     +436     
  Branches     5473     5615     +142     
==========================================
+ Hits        25204    25542     +338     
- Misses      15235    15286      +51     
- Partials     1682     1729      +47     

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

@matthewwalsh0 matthewwalsh0 added Run Smoke E2E Triggers smoke e2e on Bitrise and removed Run Smoke E2E Triggers smoke e2e on Bitrise labels Jan 14, 2025
@matthewwalsh0 matthewwalsh0 added Run Smoke E2E Triggers smoke e2e on Bitrise and removed Run Smoke E2E Triggers smoke e2e on Bitrise labels Jan 14, 2025
Copy link
Contributor

github-actions bot commented Jan 14, 2025

https://bitrise.io/ Bitrise

✅✅✅ pr_smoke_e2e_pipeline passed on Bitrise! ✅✅✅

Commit hash: 5c642c1
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/db7eec49-f819-4bcb-a3eb-2f1e51f9152f

Note

  • You can kick off another pr_smoke_e2e_pipeline on Bitrise by removing and re-applying the Run Smoke E2E label on the pull request

@matthewwalsh0 matthewwalsh0 marked this pull request as ready for review January 14, 2025 21:38
@matthewwalsh0 matthewwalsh0 requested review from a team as code owners January 14, 2025 21:38
@matthewwalsh0 matthewwalsh0 added Run Smoke E2E Triggers smoke e2e on Bitrise and removed Run Smoke E2E Triggers smoke e2e on Bitrise labels Jan 23, 2025
Copy link
Contributor

github-actions bot commented Jan 23, 2025

https://bitrise.io/ Bitrise

❌❌❌ pr_smoke_e2e_pipeline failed on Bitrise! ❌❌❌

Commit hash: ca78031
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/ed715f21-6726-4477-b77b-38147c1a9534

Note

  • You can kick off another pr_smoke_e2e_pipeline on Bitrise by removing and re-applying the Run Smoke E2E label on the pull request

Tip

  • Check the documentation if you have any doubts on how to understand the failure on bitrise

@matthewwalsh0 matthewwalsh0 added Run Smoke E2E Triggers smoke e2e on Bitrise and removed Run Smoke E2E Triggers smoke e2e on Bitrise labels Jan 24, 2025
Copy link
Contributor

github-actions bot commented Jan 24, 2025

https://bitrise.io/ Bitrise

✅✅✅ pr_smoke_e2e_pipeline passed on Bitrise! ✅✅✅

Commit hash: 07fdf51
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/c85d3ed3-b8c4-4ddc-ade0-9d00299bd6ff

Note

  • You can kick off another pr_smoke_e2e_pipeline on Bitrise by removing and re-applying the Run Smoke E2E label on the pull request

Copy link
Contributor

@EtherWizard33 EtherWizard33 left a comment

Choose a reason for hiding this comment

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

for wallet-ux, the two lines in app/components/Views/Settings/Contacts/index.js
LGTM

@matthewwalsh0 matthewwalsh0 added this pull request to the merge queue Jan 24, 2025
Merged via the queue into main with commit 2ce6596 Jan 24, 2025
41 of 42 checks passed
@matthewwalsh0 matthewwalsh0 deleted the refactor/remove-global-network-usage-transactions branch January 24, 2025 15:06
@github-actions github-actions bot locked and limited conversation to collaborators Jan 24, 2025
@metamaskbot metamaskbot added the release-7.40.0 Issue or pull request that will be included in release 7.40.0 label Jan 24, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
release-7.40.0 Issue or pull request that will be included in release 7.40.0 Run Smoke E2E Triggers smoke e2e on Bitrise team-confirmations Push issues to confirmations team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants