Skip to content

chore: add KeyringController entropy ID selectors - #10284

Merged
Gudahtt merged 1 commit into
mainfrom
refactor-keyring-hd-keyring-selectors
Sep 18, 2026
Merged

Gudahtt merged 1 commit into
mainfrom
refactor-keyring-hd-keyring-selectors

Conversation

@Gudahtt

@Gudahtt Gudahtt commented Sep 17, 2026 •

Copy link
Copy Markdown
Member

Explanation

Add selectors to the keyring-controller package for getting entropy source IDs. This is a refactor, these selectors were previously written as part of the profile-sync-controller package, but they belong with the keyring package.

References

N/A

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
  • I've introduced breaking changes in this PR and have prepared draft pull requests for clients and consumer packages to resolve them

Note

Medium Risk
Changes how multi-SRP entropy IDs are resolved for auth and encrypted user storage, though behavior should match the prior HD keyring filtering; getPrimaryHdKeyringEntropySourceId’s parameter type changed for any external callers.

Overview
Moves HD keyring entropy source ID derivation from profile-sync-controller into @metamask/keyring-controller, exporting selectHdKeyringEntropySourceIds and selectPrimaryHdKeyringEntropySourceId (with unit tests) from the package public API.

AuthenticationController and UserStorageController now call those selectors on full KeyringController:getState instead of filtering keyrings locally. The profile-sync helper getPrimaryHdKeyringEntropySourceId is narrowed to a throw-on-missing wrapper around the primary selector and now takes KeyringControllerState rather than a keyrings array; getHdKeyringEntropySourceIds is removed from shared utils.

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

Add selectors to the `keyring-controller` package for getting entropy
source IDs. This is a refactor, these selectors were previously written
as part of the `profile-sync-controller` package, but they belong with
the keyring package.
@Gudahtt
Gudahtt force-pushed the refactor-keyring-hd-keyring-selectors branch from 8132ef5 to 9c31e5c Compare September 17, 2026 17:02
@Gudahtt
Gudahtt marked this pull request as ready for review September 17, 2026 17:55
@Gudahtt
Gudahtt requested review from a team as code owners September 17, 2026 17:55
@Gudahtt
Gudahtt deployed to default-branch September 17, 2026 17:55 — with GitHub Actions Active
@Gudahtt
Gudahtt added this pull request to the merge queue Sep 18, 2026
Merged via the queue into main with commit 128a55f Sep 18, 2026
191 checks passed
@Gudahtt
Gudahtt deleted the refactor-keyring-hd-keyring-selectors branch September 18, 2026 12:13
@cursor cursor Bot mentioned this pull request Sep 24, 2026
3 of 4 tasks
pull Bot pushed a commit to Reality2byte/core that referenced this pull request Sep 24, 2026
## Explanation

<!--
Thanks for your contribution! Take a moment to answer these questions so
that reviewers have the information they need to properly understand
your changes:

* What is the current state of things and why does it need to change?
* What is the solution your changes offer and how does it work?
* Are there any changes whose purpose might not obvious to those
unfamiliar with the domain?
* If your primary goal was to update one package but you found you had
to update another one along the way, why did you do so?
* If you had to upgrade a dependency, why did you do so?
-->

## References

<!--
Are there any issues that this pull request is tied to?
Are there other links that reviewers should consult to understand these
changes better?
Are there client or consumer pull requests to adopt any breaking
changes?

For example:

* Fixes #12345
* Related to #67890
-->

## Checklist

- [x] I've updated the test suite for new or updated code as appropriate
- [x] I've updated documentation (JSDoc, Markdown, etc.) for new or
updated code as appropriate
- [x] I've communicated my changes to consumers by [updating changelogs
for packages I've
changed](https://github.com/MetaMask/core/tree/main/docs/processes/updating-changelogs.md)
- [ ] I've introduced [breaking
changes](https://github.com/MetaMask/core/tree/main/docs/processes/breaking-changes.md)
in this PR and have prepared draft pull requests for clients and
consumer packages to resolve them

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Low Risk**
> Changes are release versioning and dependency propagation only; risk
is mainly that many packages now require keyring-controller 28.1.0 at
install time.
> 
> **Overview**
> This PR cuts **monorepo release 1283.0.0** and rolls dependency
versions through the workspace.
> 
> It finalizes **`@metamask/keyring-controller` 28.1.0** (changelog
documents **entropy ID selectors** from
[MetaMask#10284](MetaMask#10284)) and
**`@metamask/profile-sync-controller` 32.3.1**, then updates **dozens of
packages** to depend on `^28.1.0` and/or `^32.3.1`, with matching
**CHANGELOG** entries and an updated **`yarn.lock`**.
> 
> There is **no new controller/source logic** in this diff—only version,
dependency, and release notes alignment so consumers pick up the new
keyring and profile-sync releases together.
> 
> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit
67a5605. Bugbot is set up for automated
code reviews on this repo. Configure
[here](https://www.cursor.com/dashboard/bugbot).</sup>
<!-- /CURSOR_SUMMARY -->

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

This branch was successfully deployed

1 active deployment
default-branch — 9c31e5c1 Deployed Sep 17, 2026 by Gudahtt via Determine whether this PR is a release PR #4244
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants