Skip to content

chore(errors): drop the @ledgerhq/errors package (LIVE-32915) - #20278

Draft
gre-ledger wants to merge 1 commit into
developfrom
chore/errors-LIVE-32915-drop-ledgerhq-errors
Draft

chore(errors): drop the @ledgerhq/errors package (LIVE-32915)#20278
gre-ledger wants to merge 1 commit into
developfrom
chore/errors-LIVE-32915-drop-ledgerhq-errors

Conversation

@gre-ledger

@gre-ledger gre-ledger commented Jul 31, 2026

Copy link
Copy Markdown
Contributor
  • merge chore(errors): ban @ledgerhq/errors as a dependency (LIVE-32915) #20280 first
  • wait new wallet-api-core is bumped so it no longer depends on @ledgerhq/errors
  • wait coin-module-framework, coin-stellar, coin-xrp and coin-hypercore also all drop @ledgerhq/errors peer dependency
  • drop any remaining @ledgerhq/errors dep injection (current workaround in package.json to feed to necessary peer deps)

Warning

Do not merge before LedgerHQ/coin-modules#752 lands and is released.
That PR removes the @ledgerhq/errors peerDependency from coin-module-framework, coin-stellar, coin-xrp and coin-hypercore. Until it ships, this PR needs the pnpm.packageExtensions bridge below to keep those external packages resolvable at runtime.

📝 Description

Removes the @ledgerhq/errors package from the monorepo. No workspace source imported it anymore — every error class it held now lives in the package that owns it, with @ledgerhq/ledger-wallet-framework/errors as the shared home below the coin layer. createCustomErrorClass and the serializeError / deserializeError stack go away with it.

Also drops all remaining references: 33 manifests, 29 .unimportedrc.json allowlists, the libs/coin-modules/.oxlintrc.json import allowlist, the root nx run-many filters and ljs:errors script, CODEOWNERS, docs and skills.

Define errors as native classes and branch on name, which survives serialization:

-import { createCustomErrorClass } from "@ledgerhq/errors";
-export const FooNotFound = createCustomErrorClass("FooNotFound");
+export class FooNotFound extends Error {
+  override name = "FooNotFound";
+}

-if (e instanceof FooNotFound) { … }
+if (e instanceof Error && e.name === "FooNotFound") { … }

The one non-obvious part. Those 33 manifests looked like dead weight — no source file imported the package — but they were load-bearing. The external @ledgerhq/coin-module-framework (and coin-stellar / coin-xrp) declare @ledgerhq/errors as a peerDependency and require() it at runtime; with auto-install-peers=false, each consumer's workspace:^ entry was what satisfied that peer. Dropping them broke coin-module-framework/config, /errors and /api/getBalance/rejectBalanceOptions — 79 import sites across 30 packages, both apps included.

So the peer is bridged from npm until #752 ships:

"packageExtensions": {
  "@ledgerhq/coin-module-framework": { "dependencies": { "@ledgerhq/errors": "6.37.0" } },
  "@ledgerhq/coin-stellar":          { "dependencies": { "@ledgerhq/errors": "6.37.0" } },
  "@ledgerhq/coin-xrp":              { "dependencies": { "@ledgerhq/errors": "6.37.0" } },
  "@ledgerhq/coin-hypercore":        { "dependencies": { "@ledgerhq/errors": "6.37.0" } }
}

Once #752 is released, bump those four catalog versions and delete the block — it is the only thing keeping @ledgerhq/errors in the dependency graph.

@ledgerhq/errors@6.37.0 stays on npm for external consumers; it is simply no longer published from this repo.

🔗 Context

Copilot AI review requested due to automatic review settings July 31, 2026 10:39
@live-github-bot live-github-bot Bot added desktop Has changes in LLD mobile Has changes in LLM common Has changes in live-common ledgerjs Has changes in the ledgerjs open source libs tools Has changes in tools coin-modules shared-lib Label added for automated tagging of PRs wallet-cli labels Jul 31, 2026
@live-github-bot live-github-bot Bot changed the title chore(errors): drop the @ledgerhq/errors package (LIVE-32915) [LWDM] chore(errors): drop the @ledgerhq/errors package (LIVE-32915) Jul 31, 2026
@github-actions

github-actions Bot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

Web Tools Build Status

Build Status Deployment
Web Tools Build ❌ Failed
Native Storybook Build ✅ Deployed https://native-ui-storybook-p7g2or2yk-ledger-hq-prd.vercel.app
React Storybook Build ✅ Deployed https://react-ui-storybook-r0vxjix3e-ledger-hq-prd.vercel.app

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR removes the deprecated @ledgerhq/errors workspace package from the Ledger Wallet monorepo and cleans up remaining repository references, while temporarily keeping runtime compatibility for external coin-module packages via pnpm.packageExtensions until upstream peerDependency removal is released.

Changes:

  • Remove the in-repo libs/ledgerjs/packages/errors package and drop all remaining workspace dependency references to @ledgerhq/errors.
  • Add pnpm.packageExtensions to inject @ledgerhq/errors@6.37.0 as a dependency for @ledgerhq/coin-module-framework, coin-stellar, coin-xrp, and coin-hypercore (external packages that still require() it).
  • Update boundary tooling/tests, coin-modules allowlists/docs, and agent skills/docs to reflect the migration to native Error classes and error.name checks.

Reviewed changes

Copilot reviewed 91 out of 92 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tools/nx-plugins/enforce-boundaries/validate.test.js Updates legacy import test fixtures now that @ledgerhq/errors is removed.
tools/nx-plugins/enforce-boundaries/validate.js Updates inline documentation example for sub-path stripping.
pnpm-lock.yaml Lockfile updates reflecting removal of workspace @ledgerhq/errors and new packageExtensions-injected deps.
package.json Removes ljs:errors/build filters and adds pnpm.packageExtensions bridge for external coin modules.
libs/ledgerjs/packages/hw-app-celo/.unimportedrc.json Removes now-unneeded @ledgerhq/errors ignore entry.
libs/ledgerjs/packages/errors/tsconfig.json Deletes config as part of removing the @ledgerhq/errors package.
libs/ledgerjs/packages/errors/tsconfig.build.json Deletes build config as part of removing the @ledgerhq/errors package.
libs/ledgerjs/packages/errors/src/index.ts Removes the legacy error exports implementation.
libs/ledgerjs/packages/errors/src/index.test.ts Removes package tests along with the package.
libs/ledgerjs/packages/errors/src/helpers.ts Removes legacy createCustomErrorClass + serialization helpers with the package.
libs/ledgerjs/packages/errors/src/deserializeError.test.ts Removes serialization resiliency tests with the package.
libs/ledgerjs/packages/errors/README.md Removes package README along with the package.
libs/ledgerjs/packages/errors/package.json Removes the workspace package manifest.
libs/ledgerjs/packages/errors/jest.config.ts Removes package Jest config along with the package.
libs/ledgerjs/packages/errors/DEPRECATED.md Removes deprecated-package guidance along with the package.
libs/ledgerjs/packages/errors/CHANGELOG.md Removes package changelog along with the package.
libs/ledgerjs/packages/errors/.unimportedrc.json Removes unimported config along with the package.
libs/ledger-live-common/src/exchange/swap/completeExchange.ts Adjusts comment wording to reflect migration away from shared error class checks.
libs/ledger-live-common/package.json Drops @ledgerhq/errors dependency.
libs/ledger-live-common/dependencies.md Removes @ledgerhq/errors from dependency tracking doc.
libs/coin-tester-modules/coin-tester-xrp/package.json Drops @ledgerhq/errors dependency.
libs/coin-tester-modules/coin-tester-xrp/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-tester-modules/coin-tester-stellar/package.json Drops @ledgerhq/errors dependency.
libs/coin-tester-modules/coin-tester-stellar/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-tester-modules/coin-tester-polkadot/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-tester-modules/coin-tester-cosmos/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/README.md Updates allowed-import documentation to remove @ledgerhq/errors and include framework errors home.
libs/coin-modules/coin-vechain/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-vechain/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-tron/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-tron/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-ton/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-ton/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-tezos/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-tezos/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-sui/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-sui/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-stacks/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-solana/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-solana/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-polkadot/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-polkadot/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-near/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-near/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-multiversx/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-multiversx/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-module-boilerplate/package.json Drops @ledgerhq/errors dependency (template upkeep).
libs/coin-modules/coin-module-boilerplate/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-mina/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-kaspa/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-kaspa/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-internet_computer/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-internet_computer/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-icon/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-icon/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-hedera/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-hedera/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-filecoin/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-filecoin/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-evm/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-evm/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-cosmos/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-cosmos/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-concordium/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-celo/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-celo/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-casper/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-casper/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-cardano/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-cardano/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-canton/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-bitcoin/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-bitcoin/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-aptos/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-aptos/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-algorand/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-algorand/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/coin-aleo/package.json Drops @ledgerhq/errors dependency.
libs/coin-modules/coin-aleo/.unimportedrc.json Removes @ledgerhq/errors ignore entry.
libs/coin-modules/.oxlintrc.json Removes @ledgerhq/errors from restricted-import allowlist.
features/platform/currencies/src/errors.ts Updates docs to remove references to legacy @ledgerhq/errors.
features/platform/currencies/README.md Aligns feature README with native error-class approach.
docs/new-library.md Updates new-library checklist to remove @ledgerhq/errors guidance.
CODEOWNERS Removes codeownership entry for deleted @ledgerhq/errors source file.
apps/wallet-cli/src/device/classify-device-error.ts Updates comments to remove references to @ledgerhq/errors.
apps/ledger-live-mobile/package.json Drops @ledgerhq/errors dependency.
apps/ledger-live-desktop/package.json Drops @ledgerhq/errors dependency.
.changeset/LIVE-32915-remove-errors-package.md Adds changeset documenting removal and migration guidance.
.changeset/LIVE-32915-drop-serialize-deserialize-errors.md Removes now-irrelevant changeset targeting the deleted package.
.agents/skills/impacting-prs/SKILL.md Updates skill docs/examples to remove @ledgerhq/errors-specific wording.
.agents/skills/errors/SKILL.md Updates errors skill to reflect post-@ledgerhq/errors guidance (needs minor wording tweak).
.agents/skills/coin-modules/SKILL.md Updates coin-modules skill allowed-import guidance to remove @ledgerhq/errors.
Files not reviewed (1)
  • pnpm-lock.yaml: Generated file

Comment thread .agents/skills/errors/SKILL.md Outdated
@github-actions

Copy link
Copy Markdown
Contributor

Rsdoctor Bundle Diff Analysis

Found 7 projects in monorepo, 7 projects with changes.

📊 Quick Summary
Project Total Size Change
desktop-main 2.3 MB -
desktop-preloader 7.1 KB -
desktop-renderer 80.7 MB -
desktop-webviewDappPreloader 36.9 KB -
desktop-webviewPreloader 200.0 B -
desktop-workers 36.8 KB -
mobile 261.5 MB -
📋 Detailed Reports (Click to expand)

📁 desktop-main

Path: rsdoctor/desktop-main/rsdoctor-data.json

⚠️ No baseline data found - Unable to perform comparison analysis

Metric Current Baseline Change
📊 Total Size 2.3 MB - -
📄 JavaScript 2.2 MB - -
🎨 CSS 0 B - -
🌐 HTML 0 B - -
📁 Other Assets 135.3 KB - -

📁 desktop-preloader

Path: rsdoctor/desktop-preloader/rsdoctor-data.json

⚠️ No baseline data found - Unable to perform comparison analysis

Metric Current Baseline Change
📊 Total Size 7.1 KB - -
📄 JavaScript 5.3 KB - -
🎨 CSS 0 B - -
🌐 HTML 0 B - -
📁 Other Assets 1.8 KB - -

📁 desktop-renderer

Path: rsdoctor/desktop-renderer/rsdoctor-data.json

⚠️ No baseline data found - Unable to perform comparison analysis

Metric Current Baseline Change
📊 Total Size 80.7 MB - -
📄 JavaScript 29.3 MB - -
🎨 CSS 183.1 KB - -
🌐 HTML 1.8 KB - -
📁 Other Assets 51.2 MB - -

📁 desktop-webviewDappPreloader

Path: rsdoctor/desktop-webviewDappPreloader/rsdoctor-data.json

⚠️ No baseline data found - Unable to perform comparison analysis

Metric Current Baseline Change
📊 Total Size 36.9 KB - -
📄 JavaScript 36.9 KB - -
🎨 CSS 0 B - -
🌐 HTML 0 B - -
📁 Other Assets 0 B - -

📁 desktop-webviewPreloader

Path: rsdoctor/desktop-webviewPreloader/rsdoctor-data.json

⚠️ No baseline data found - Unable to perform comparison analysis

Metric Current Baseline Change
📊 Total Size 200.0 B - -
📄 JavaScript 200.0 B - -
🎨 CSS 0 B - -
🌐 HTML 0 B - -
📁 Other Assets 0 B - -

📁 desktop-workers

Path: rsdoctor/desktop-workers/rsdoctor-data.json

⚠️ No baseline data found - Unable to perform comparison analysis

Metric Current Baseline Change
📊 Total Size 36.8 KB - -
📄 JavaScript 36.8 KB - -
🎨 CSS 0 B - -
🌐 HTML 0 B - -
📁 Other Assets 0 B - -

📁 mobile

Path: rsdoctor/mobile/rsdoctor-data.json

⚠️ No baseline data found - Unable to perform comparison analysis

Metric Current Baseline Change
📊 Total Size 261.5 MB - -
📄 JavaScript 110.5 MB - -
🎨 CSS 0 B - -
🌐 HTML 0 B - -
📁 Other Assets 151.0 MB - -

Generated by Rsdoctor GitHub Action

@live-github-bot

live-github-bot Bot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

Desktop Bundle Checks

Comparing fcd25af against 5e31ac5.

⚠️ @ledgerhq/errors library is now duplicated in renderer (regression)

Mobile Bundle Checks

Comparing fcd25af against 5e31ac5.

@gre-ledger
gre-ledger force-pushed the chore/errors-LIVE-32915-drop-ledgerhq-errors branch from 196c551 to bdf815f Compare July 31, 2026 10:53
Copilot AI review requested due to automatic review settings July 31, 2026 10:53

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 91 out of 92 changed files in this pull request and generated no new comments.

Files not reviewed (1)
  • pnpm-lock.yaml: Generated file
Suppressed comments (1)

package.json:353

  • pnpm.packageExtensions keys currently target the package name without a version selector, so this extension will keep applying even after bumping @ledgerhq/coin-module-framework / coin-stellar / coin-xrp / coin-hypercore to versions that no longer need @ledgerhq/errors. Scoping the selector to the current versions makes the bridge self-expiring and reduces the risk of accidentally keeping @ledgerhq/errors in the dependency graph after the upstream fix is released.

@gre-ledger

Copy link
Copy Markdown
Contributor Author

Important

Superseded by #20280 — do not merge this.

The pnpm.packageExtensions bridge here pins @ledgerhq/errors@6.37.0 from npm, which adds a 4th physical copy of the package next to the third-party 6.36.0 / 6.32.0 / 5.50.0 already in the graph. Develop shares a single workspace copy instead, so Desktop Bundle Checks correctly reports @ledgerhq/errors library is now duplicated in renderer (regression).

#20280 does the same de-dependency work but keeps the package in-repo and bridges the external peer with workspace:*, so the physical copies stay byte-identical to develop. Deleting the package becomes a follow-up once LedgerHQ/coin-modules#752 lands and coin-module-framework / coin-stellar / coin-xrp / coin-hypercore are released without the peerDependency.

@sonarqubecloud

Copy link
Copy Markdown

@gre-ledger

Copy link
Copy Markdown
Contributor Author

Preconditions for the full sunset

Confirmed: wallet-api@916d7a3 ("chore: remove @ledgerhq/errors dependency", #598) does exactly what is needed — it drops the dep from both packages/core and packages/simulator and replaces serializeError/deserializeError with a local packages/core/src/errors/serialization.ts. It carries a changeset, so all that is missing is a release: npm still shows @ledgerhq/wallet-api-core@1.35.0 as latest, with "@ledgerhq/errors": "^6.35.0".

So deleting @ledgerhq/errors from this repo needs three things, and they are independent:

# Precondition Unblocks
1 coin-modules#752 released drops the peerDependency from coin-module-framework / coin-stellar / coin-xrp / coin-hypercore, so the pnpm.packageExtensions bridge and the nx build-order edge can both go
2 a wallet-api release containing 916d7a3, then a lockfile refresh removes the 6.36.0 copy. Our pin is "@ledgerhq/wallet-api-core": "^1.35.0" (libs/ledger-live-common/package.json), so a new minor needs only pnpm up, no manifest change
3 1 + 2 done pnpm.overrides can go and the package can be deleted

Why 2 matters beyond tidiness

The renderer duplication reported on this PR is version-based — extractDuplicatesFromRspack flags a package only when it sees two or more distinct versions under node_modules/.pnpm/@ledgerhq+errors@<version>/. On this branch the renderer contained exactly two:

  • 6.36.0 — from @ledgerhq/wallet-api-core@1.35.0 (143 modules in the renderer)
  • 6.32.0 — from iso-filecoin@7.4.7 (8 modules) and @mysten/ledgerjs-hw-app-sui@0.8.0 (1 module)

Once wallet-api-core is bumped, the 6.36.0 copy disappears and the only remaining external consumers — iso-filecoin and @mysten/ledgerjs-hw-app-suiboth pin 6.32.0. One version, so the detector stays quiet. That means after precondition 2, deleting the package does not reintroduce a duplication regression, and no override is needed to keep it quiet.

Neither of those two is a Ledger package, so they will keep resolving 6.32.0 from npm after we stop publishing — nothing breaks for them.

No workspace source imported the lib anymore: every error class it held now lives in
the package that owns it, with @ledgerhq/ledger-wallet-framework/errors as the shared
home below the coin layer. This removes the package itself plus all remaining
references (manifests, lint and unimported allowlists, root nx filters, CODEOWNERS,
docs and skills).

The external @ledgerhq/coin-module-framework, coin-stellar, coin-xrp and coin-hypercore
still declare @ledgerhq/errors as a peerDependency and require it at runtime, so the
peer is bridged from npm via pnpm.packageExtensions. That bridge is temporary and
should be deleted once LedgerHQ/coin-modules#752 lands and is released.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@gre-ledger
gre-ledger force-pushed the chore/errors-LIVE-32915-drop-ledgerhq-errors branch from bdf815f to 0162219 Compare July 31, 2026 17:45
Copilot AI review requested due to automatic review settings July 31, 2026 17:45
@live-github-bot live-github-bot Bot removed desktop Has changes in LLD mobile Has changes in LLM common Has changes in live-common coin-modules labels Jul 31, 2026
@live-github-bot live-github-bot Bot removed shared-lib Label added for automated tagging of PRs wallet-cli labels Jul 31, 2026
@live-github-bot live-github-bot Bot changed the title [LWDM] chore(errors): drop the @ledgerhq/errors package (LIVE-32915) chore(errors): drop the @ledgerhq/errors package (LIVE-32915) Jul 31, 2026
"@ledgerhq/coin-vechain": patch
"@ledgerhq/live-common": patch
"ledger-live-desktop": patch
"live-mobile": patch

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

fixme refine the diff for the actual subset of lib that are effectively dropping these

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 21 out of 22 changed files in this pull request and generated 1 comment.

Files not reviewed (1)
  • pnpm-lock.yaml: Generated file
Suppressed comments (2)

tools/nx-plugins/enforce-boundaries/constraints.js:56

  • BANNED_DEPENDENCIES is now empty, which disables the safeguard added in #20280 that prevented reintroducing @ledgerhq/errors via workspace manifests. Since @ledgerhq/errors still exists on npm, this change makes it easy for new code to accidentally add it back without any enforce-boundaries failure.
/**
 * Packages no workspace manifest may declare, whatever the dependency field.
 *
 * `hoist=false` means a package can only resolve what it declares, so banning the
 * declaration is enough to ban the import too — an undeclared import fails to resolve.
 */
const BANNED_DEPENDENCIES = [];

module.exports = { DEP_CONSTRAINTS, BOUNDARY_EXCEPTIONS, BANNED_DEPENDENCIES };

pnpm-lock.yaml:46548

  • The lockfile now shows @ledgerhq/coin-module-framework / coin-* snapshots without an @ledgerhq/errors dependency (even though those packages still declare it as a peerDependency in the same lockfile). With auto-install-peers=false, this is a strong sign that the peer won’t be provided at runtime; after restoring the pnpm.packageExtensions bridge in package.json, please regenerate pnpm-lock.yaml so these snapshots reflect the injected dependency.

Comment thread package.json
Comment on lines 318 to 334
"packageExtensions": {
"detox-allure2-adapter": {
"dependencies": {
"tslib": "*"
}
},
"tronweb": {
"dependencies": {
"tslib": "*"
}
},
"detox": {
"dependencies": {
"expect": "*"
}
},
"@ledgerhq/coin-module-framework": {
"dependencies": {
"@ledgerhq/errors": "workspace:*"
}
},
"@ledgerhq/coin-stellar": {
"dependencies": {
"@ledgerhq/errors": "workspace:*"
}
},
"@ledgerhq/coin-xrp": {
"dependencies": {
"@ledgerhq/errors": "workspace:*"
}
},
"@ledgerhq/coin-hypercore": {
"dependencies": {
"@ledgerhq/errors": "workspace:*"
}
}
},

@gre-ledger gre-ledger Jul 31, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

here we're just anticipating the drop

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

Labels

ledgerjs Has changes in the ledgerjs open source libs tools Has changes in tools

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants