Skip to content

chore: bump compliance controller to 2.1.0#30906

Merged
geositta merged 4 commits into
mainfrom
feat/compliance-account-update
Jun 4, 2026
Merged

chore: bump compliance controller to 2.1.0#30906
geositta merged 4 commits into
mainfrom
feat/compliance-account-update

Conversation

@geositta

@geositta geositta commented Jun 1, 2026

Copy link
Copy Markdown
Contributor

Description

This PR updates mobile to consume @metamask/compliance-controller@2.1.0 and wires the mobile compliance setup to use the configured Compliance API URL.

The reason for this change is to bring mobile onto the latest compliance-controller release that supports explicit API URL configuration and shared wallet-blocked selectors. That support is needed for the broader compliance work so mobile can resolve compliance checks through build configuration instead of relying only on the controller package’s environment fallback.

The solution bumps the compliance-controller dependency, passes COMPLIANCE_API_URL into ComplianceService, adds the URL to mobile build configuration, and updates the mobile selector wrapper to use the core batch blocked-wallet selector. Tests were updated to cover the configured API URL wiring and the EVM case-insensitive address matching behavior from the released controller package.

Changelog

CHANGELOG entry: null

Related issues

Fixes:

Manual testing steps

Feature: my feature name

  Scenario: user [verb for user action]
    Given [describe expected initial app state]

    When user [verb for user action]
    Then [describe expected outcome]

Screenshots/Recordings

Before

After

Pre-merge author checklist

Performance checks (if applicable)

  • I've tested on Android
    • Ideally on a mid-range device; emulator is acceptable
  • I've tested with a power user scenario
    • Use these power-user SRPs to import wallets with many accounts and tokens
  • I've instrumented key operations with Sentry traces for production performance metrics

For performance guidelines and tooling, see the Performance Guide.

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.

Note

Medium Risk
Changes which compliance API URL the wallet uses and how blocked-address lookups behave (including EVM case-insensitivity), which can affect send/receive gating if misconfigured.

Overview
Upgrades @metamask/compliance-controller from 2.0.0 to 2.1.0 and threads a configurable compliance backend URL through mobile builds.

ComplianceService now receives apiUrl from COMPLIANCE_API_URL (with existing prod/dev env unchanged). That variable is added to .js.env.example, shared builds.yml public envs, jest.config.js, and apply-build-config.js so CI and local builds hit the production compliance host by default.

The Redux selectAreAnyWalletsBlocked wrapper delegates to the package’s coreSelectAreAnyWalletsBlocked instead of looping selectIsWalletBlocked locally, aligning multichain “any blocked” checks with controller logic (including case-insensitive EVM matching). Tests and the Jest manual mock were updated for apiUrl wiring and address matching behavior.

Reviewed by Cursor Bugbot for commit a6652a8. Bugbot is set up for automated code reviews on this repo. Configure here.

@github-actions

github-actions Bot commented Jun 1, 2026

Copy link
Copy Markdown
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.

@mm-token-exchange-service mm-token-exchange-service Bot added the team-perps Perps team label Jun 1, 2026
@socket-security

socket-security Bot commented Jun 1, 2026

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Updatednpm/​@​metamask/​compliance-controller@​2.0.0 ⏵ 2.1.074 +11009493100

View full report

@github-actions github-actions Bot added the size-M label Jun 1, 2026
@geositta geositta marked this pull request as ready for review June 2, 2026 19:58
@geositta geositta requested review from a team as code owners June 2, 2026 19:58
@github-actions github-actions Bot added the risk:high AI analysis: high risk label Jun 2, 2026
* Manual mock for @metamask/compliance-controller.
*
* Reflects the v2.0.0 public API surface: the bulk-fetch blocklist pattern.
* Reflects the v2.1.0 public API surface: the bulk-fetch blocklist pattern.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This comment is nice but I feel like it's something that could easily be missed and cause confusion, I'd opt to omit the version number entirely here

gambinish
gambinish previously approved these changes Jun 2, 2026
@github-actions

github-actions Bot commented Jun 3, 2026

Copy link
Copy Markdown
Contributor

🔍 Smart E2E Test Selection

  • Selected E2E tags: SmokeAccounts, SmokeConfirmations, SmokeIdentity, SmokeNetworkAbstractions, SmokeNetworkExpansion, SmokeSwap, SmokeStake, SmokeWalletPlatform, SmokeMoney, SmokePerps, SmokeMultiChainAPI, SmokePredictions, SmokeSeedlessOnboarding, SmokeBrowser, SmokeSnaps
  • Selected Performance tags: @PerformanceAccountList, @PerformanceOnboarding, @PerformanceLogin, @PerformanceSwaps, @PerformanceLaunch, @PerformanceAssetLoading, @PerformancePredict, @PerformancePreps
  • Risk Level: high
  • AI Confidence: 100%
click to see 🤖 AI reasoning details

E2E Test Selection:
Hard rule (controller-version-update): @MetaMask controller package version updated in package.json: @metamask/compliance-controller. Running all tests.

Performance Test Selection:
Hard rule (controller-version-update): @MetaMask controller package version updated in package.json: @metamask/compliance-controller. Running all tests.

View GitHub Actions results

@geositta geositta enabled auto-merge June 3, 2026 14:50
@geositta geositta added this pull request to the merge queue Jun 4, 2026
Merged via the queue into main with commit 6ca1693 Jun 4, 2026
233 checks passed
@geositta geositta deleted the feat/compliance-account-update branch June 4, 2026 17:40
@github-actions github-actions Bot locked and limited conversation to collaborators Jun 4, 2026
@metamaskbotv2 metamaskbotv2 Bot added the release-7.81.0 Issue or pull request that will be included in release 7.81.0 label Jun 4, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

release-7.81.0 Issue or pull request that will be included in release 7.81.0 risk:high AI analysis: high risk size-M team-perps Perps team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants