From 3fa230c2695ebfaa54bd6d9da6be0df17cad13b2 Mon Sep 17 00:00:00 2001 From: Maxime OUAIRY Date: Thu, 13 Aug 2026 15:35:13 +0200 Subject: [PATCH 1/3] fix(assets-controller): default-track Arc's native USDC id instead of its ERC20 identity Arc's native gas token is USDC, but Arc's Accounts-API balance fetch always succeeds for the ERC20 identity, which short-circuits the RPC fallback path that would otherwise be the only place writing `type: 'native'` metadata for the native asset id. Without that metadata, the zero-balance native entry `#ensureNativeBalancesDefaultZero` seeds for every chain has nothing to be recognized by, and clients that gate rendering on `assetsInfo[assetId]?.type === 'native'` (e.g. metamask-mobile's assets-migration.ts) silently drop the row until the account's first deposit triggers a different code path. Default-track the native id (`eip155:5042/slip44:5042`) instead of the `0x3600...` ERC20 identity, which is no longer a valid representation to track here. --- packages/assets-controller/CHANGELOG.md | 4 +++ packages/assets-controller/src/defaults.ts | 35 ++++++++++++++-------- 2 files changed, 27 insertions(+), 12 deletions(-) diff --git a/packages/assets-controller/CHANGELOG.md b/packages/assets-controller/CHANGELOG.md index aefa1d0c02d..a8d68407b5c 100644 --- a/packages/assets-controller/CHANGELOG.md +++ b/packages/assets-controller/CHANGELOG.md @@ -11,6 +11,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Bump `@metamask/transaction-controller` from `^69.5.1` to `^69.5.2` ([#9823](https://github.com/MetaMask/core/pull/9823)) +### Fixed + +- Fix Arc native USDC never appearing until the account receives its first deposit, by default-tracking the native asset id (`eip155:5042/slip44:5042`) instead of the `0x3600...` ERC20 identity so `assetsInfo` metadata is seeded up front ([#PR_NUMBER](https://github.com/MetaMask/core/pull/PR_NUMBER)) + ## [13.1.2] ### Changed diff --git a/packages/assets-controller/src/defaults.ts b/packages/assets-controller/src/defaults.ts index 6c587cddf85..86555afa8e2 100644 --- a/packages/assets-controller/src/defaults.ts +++ b/packages/assets-controller/src/defaults.ts @@ -32,20 +32,31 @@ const MUSD_METADATA: FungibleAssetMetadata = { }; /** - * Harcoded metadata for USDC on Arc (5042/0x13b2). - * USDC exists as both native (18 decimals) and ERC20 (6 decimals). - * We choose to force-hide the native version to avoid double listing using - * `CHAIN_IDS_WITH_NO_NATIVE_TOKEN`. - * In the meantime, the code below force-shows USDC the ERC20 token. + * Hardcoded metadata for native USDC on Arc (5042/0x13b2). + * + * Arc's native gas token is USDC. It's a default tracked asset (see + * `DEFAULT_TRACKED_ASSETS_BY_CHAIN` below) so `#ensureDefaultTrackedAssetsSeeded` + * writes both a zero `assetsBalance` entry and this `assetsInfo` metadata up + * front. That explicit metadata seed is required because it can never arrive + * from a live poll: Arc's Accounts-API balance fetch always succeeds, which + * marks the chain "handled" and skips the RPC fallback path that would + * otherwise be the only place writing `type: 'native'` for this id. Without + * a metadata entry here, the zero-balance native row that + * `#ensureNativeBalancesDefaultZero` seeds for every chain has no + * `type: 'native'` to be recognized by, and is silently dropped by clients + * that gate rendering on it (e.g. metamask-mobile's `assets-migration.ts`). + * + * The `0x3600...` ERC20 interface for USDC on Arc is no longer tracked here + * — it's not a valid representation to default-track anymore now that the + * native id carries its own metadata directly. */ -const USDC_ON_ARC_ASSET_ID = - 'eip155:5042/erc20:0x3600000000000000000000000000000000000000'; +const ARC_NATIVE_ASSET_ID = 'eip155:5042/slip44:5042'; -const USDC_ON_ARC_METADATA: FungibleAssetMetadata = { - type: 'erc20', +const ARC_NATIVE_METADATA: FungibleAssetMetadata = { + type: 'native', symbol: 'USDC', name: 'USDC', - decimals: 6, + decimals: 18, }; /** @@ -76,7 +87,7 @@ export const DEFAULT_TRACKED_ASSETS_BY_CHAIN: ReadonlyMap< ['eip155:1' as ChainId, [musdAssetId('eip155:1' as ChainId)]], ['eip155:59144' as ChainId, [musdAssetId('eip155:59144' as ChainId)]], ['eip155:143' as ChainId, [musdAssetId('eip155:143' as ChainId)]], - ['eip155:5042' as ChainId, [USDC_ON_ARC_ASSET_ID]], + ['eip155:5042' as ChainId, [ARC_NATIVE_ASSET_ID]], ]); /** @@ -97,7 +108,7 @@ export const DEFAULT_ASSET_METADATA: ReadonlyMap = [musdAssetId('eip155:1' as ChainId), MUSD_METADATA], [musdAssetId('eip155:59144' as ChainId), MUSD_METADATA], [musdAssetId('eip155:143' as ChainId), MUSD_METADATA], - [USDC_ON_ARC_ASSET_ID, USDC_ON_ARC_METADATA], + [ARC_NATIVE_ASSET_ID, ARC_NATIVE_METADATA], ]); /** From f37a42702fff98a60a2a4b78cae5729d5eb6d688 Mon Sep 17 00:00:00 2001 From: Maxime OUAIRY Date: Thu, 13 Aug 2026 15:46:28 +0200 Subject: [PATCH 2/3] chore(assets-controller): fill in PR number in changelog --- packages/assets-controller/CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/assets-controller/CHANGELOG.md b/packages/assets-controller/CHANGELOG.md index a8d68407b5c..b16c262a6b3 100644 --- a/packages/assets-controller/CHANGELOG.md +++ b/packages/assets-controller/CHANGELOG.md @@ -13,7 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed -- Fix Arc native USDC never appearing until the account receives its first deposit, by default-tracking the native asset id (`eip155:5042/slip44:5042`) instead of the `0x3600...` ERC20 identity so `assetsInfo` metadata is seeded up front ([#PR_NUMBER](https://github.com/MetaMask/core/pull/PR_NUMBER)) +- Fix Arc native USDC never appearing until the account receives its first deposit, by default-tracking the native asset id (`eip155:5042/slip44:5042`) instead of the `0x3600...` ERC20 identity so `assetsInfo` metadata is seeded up front ([#9869](https://github.com/MetaMask/core/pull/9869)) ## [13.1.2] From d46df6c7a34206a284300f87d9411ed6857f5efd Mon Sep 17 00:00:00 2001 From: Maxime OUAIRY Date: Thu, 13 Aug 2026 15:53:47 +0200 Subject: [PATCH 3/3] chore(assets-controller): shorten Arc native USDC comment --- packages/assets-controller/src/defaults.ts | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/packages/assets-controller/src/defaults.ts b/packages/assets-controller/src/defaults.ts index 86555afa8e2..613819c7002 100644 --- a/packages/assets-controller/src/defaults.ts +++ b/packages/assets-controller/src/defaults.ts @@ -32,23 +32,8 @@ const MUSD_METADATA: FungibleAssetMetadata = { }; /** - * Hardcoded metadata for native USDC on Arc (5042/0x13b2). - * - * Arc's native gas token is USDC. It's a default tracked asset (see - * `DEFAULT_TRACKED_ASSETS_BY_CHAIN` below) so `#ensureDefaultTrackedAssetsSeeded` - * writes both a zero `assetsBalance` entry and this `assetsInfo` metadata up - * front. That explicit metadata seed is required because it can never arrive - * from a live poll: Arc's Accounts-API balance fetch always succeeds, which - * marks the chain "handled" and skips the RPC fallback path that would - * otherwise be the only place writing `type: 'native'` for this id. Without - * a metadata entry here, the zero-balance native row that - * `#ensureNativeBalancesDefaultZero` seeds for every chain has no - * `type: 'native'` to be recognized by, and is silently dropped by clients - * that gate rendering on it (e.g. metamask-mobile's `assets-migration.ts`). - * - * The `0x3600...` ERC20 interface for USDC on Arc is no longer tracked here - * — it's not a valid representation to default-track anymore now that the - * native id carries its own metadata directly. + * Arc's native USDC also exists as its own ERC20 (`0x3600...`); Accounts API + * resolves that identity without ever seeding native `assetsInfo` metadata. */ const ARC_NATIVE_ASSET_ID = 'eip155:5042/slip44:5042';