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: set useRequestQueue on by default #24274

Merged
merged 5 commits into from
May 8, 2024
Merged

feat: set useRequestQueue on by default #24274

merged 5 commits into from
May 8, 2024

Conversation

NidhiKJha
Copy link
Member

This PR is to ensure that useRequestQueue is set to true by default. After setting it to true, it turn the setting on for all users while keeping the toggle, since this is a state update. This PR also includes a migration.

Related issues

Fixes: #23985

Manual testing steps

  1. Go to settings > Experimental
  2. Check Select networks for each site toggle is on
  3. Toggle should work properly

Screenshots/Recordings

Before

Screenshot 2024-04-29 at 12 43 31 PM

After

Screenshot 2024-04-29 at 12 43 03 PM

Pre-merge author checklist

  • I’ve followed MetaMask Coding Standards.
  • I've completed the PR template to the best of my ability
  • I’ve included tests if applicable
  • I’ve documented my code using JSDoc format if applicable
  • I’ve applied the right labels on the PR (see labeling guidelines). Not required for external contributors.

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.

@NidhiKJha NidhiKJha requested a review from a team as a code owner April 29, 2024 07:15
@NidhiKJha NidhiKJha added team-wallet-ux needs-assets-ux-review A shared label between the Assets and UX team to flag PRs ready for consolidated team review. labels Apr 29, 2024
@metamaskbot metamaskbot added the INVALID-PR-TEMPLATE PR's body doesn't match template label Apr 29, 2024
return versionedData;
}

// TODO: Replace `any` with specific type
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we fix this TODO?

return state;
}

if (!isObject(state.PreferencesController)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

What sort of values can state.PreferencesController have?

@NidhiKJha NidhiKJha requested a review from kumavis as a code owner April 30, 2024 10:40
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.

@NidhiKJha NidhiKJha force-pushed the fix-23985 branch 2 times, most recently from ca46fcc to 1644fac Compare April 30, 2024 10:44
@adonesky1
Copy link
Contributor

MetaMask provider should inform dapp when switching networks is failing because the expected behavior its testing has actually changed: we should no longer expect for the network of the dapp not to change when you change the network in network switcher in full screen

@adonesky1
Copy link
Contributor

This PR should resolve at least one of the test failures on this PR: Test Snap RPC can use the cross-snap RPC endowment and produce a public key

@metamaskbot metamaskbot added the needs-dev-review PR needs reviews from other engineers (in order to receive required approvals) label May 6, 2024
salimtb
salimtb previously approved these changes May 6, 2024
@hesterbruikman hesterbruikman added the amon-hen-v1 Represents blocking issues for the release of Amon Hen label May 7, 2024
@metamaskbot
Copy link
Collaborator

Builds ready [4b5956f]
Page Load Metrics (1032 ± 635 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint60173963115
domContentLoaded97121178
load49313510321322635
domInteractive97121178
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 1.12 KiB (0.03%)
  • ui: 0 Bytes (0.00%)
  • common: 0 Bytes (0.00%)

Copy link

codecov bot commented May 7, 2024

Codecov Report

Attention: Patch coverage is 83.33333% with 3 lines in your changes are missing coverage. Please review.

Project coverage is 67.37%. Comparing base (d27a233) to head (4b5956f).
Report is 23 commits behind head on develop.

Files Patch % Lines
app/scripts/migrations/119.ts 83.33% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff            @@
##           develop   #24274    +/-   ##
=========================================
  Coverage    67.37%   67.37%            
=========================================
  Files         1278     1286     +8     
  Lines        49881    50070   +189     
  Branches     12944    12997    +53     
=========================================
+ Hits         33605    33734   +129     
- Misses       16276    16336    +60     

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

@@ -9,47 +9,6 @@ const {
const FixtureBuilder = require('../../fixture-builder');

describe('MetaMask', function () {
it('provider should inform dapp when switching networks', async function () {
Copy link
Contributor

Choose a reason for hiding this comment

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

I suppose we could add this back with the step to toggle off the setting, like we did with the wallet_switchEthereumChain e2e test

@@ -29,6 +29,28 @@ describe('Switch Ethereum Chain for two dapps', function () {
async ({ driver }) => {
Copy link
Contributor

Choose a reason for hiding this comment

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

we should possibly add either a comment or some note in the description about how this toggles off the per dapp selected network setting

@NidhiKJha NidhiKJha merged commit a51eb93 into develop May 8, 2024
72 checks passed
@NidhiKJha NidhiKJha deleted the fix-23985 branch May 8, 2024 04:27
@github-actions github-actions bot locked and limited conversation to collaborators May 8, 2024
@github-actions github-actions bot removed the needs-dev-review PR needs reviews from other engineers (in order to receive required approvals) label May 8, 2024
@metamaskbot
Copy link
Collaborator

Missing release label release-11.17.0 on PR. Adding release label release-11.17.0 on PR and removing other release labels(release-11.18.0), as PR was added to branch 11.17.0 when release was cut.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
amon-hen-v1 Represents blocking issues for the release of Amon Hen INVALID-PR-TEMPLATE PR's body doesn't match template needs-assets-ux-review A shared label between the Assets and UX team to flag PRs ready for consolidated team review. release-12.0.0 team-wallet-ux
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

UX: Multichain: Set useRequestQueue on by default
8 participants