Skip to content

Conversation

@jiexi
Copy link
Contributor

@jiexi jiexi commented Nov 17, 2025

Explanation

BackgroundBridge returns checksummed addresses in the metamask_accountsChanged event but lowercase in the eth_accounts responses. This PR "fixes" that by lowercasing the incoming metamask_accoutnsChanged addresses. This also aligns with how addresses are presented to the dapp in the injected EIP-1193 provider

References

Fixes: https://consensyssoftware.atlassian.net/browse/WAPI-834

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've communicated my changes to consumers by updating changelogs for packages I've changed, highlighting breaking changes as necessary
  • I've prepared draft pull requests for clients and consumer packages to resolve any breaking changes

@jiexi jiexi requested a review from a team as a code owner November 17, 2025 21:12
@jiexi jiexi changed the title lowercase metamask_accountsChanged addresses fix: lowercase metamask_accountsChanged address casing to match eth_accounts Nov 17, 2025

- Fix connections made from within the MetaMask Mobile In-App Browser ([#21](https://github.com/MetaMask/connect-monorepo/pull/21))
- Bump `@metamask/multichain-api-client` to prevent JSON RPC request ID conflicts across disconnect/reconnect cycles ([#38](https://github.com/MetaMask/connect-monorepo/pull/38))
- Lowercase cached account address values from `metamask_accountsChanged` to align with `eth_accounts` ([#40](https://github.com/MetaMask/connect-monorepo/pull/40))
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this doesn't really matter unless you're using the connect-evm package though

Copy link
Member

Choose a reason for hiding this comment

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

Should we specify that this only applies to legacy connector package then ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants