chore: drop cosmos-signer override (0.2.0 published) + fix cross-file mock leaks - #140
Merged
Merged
Conversation
…ross-file mock leaks The 0.1.0 override was a stopgap while toolboxes' cosmos-signer@0.2.0 peer was unpublished; 0.2.0 is on npm now, so the override goes and the lockfile re-resolves to it. The re-resolution dedupes shared deps across workspace packages, which surfaced a latent test bug: four test files replace shared modules via mock.module (ethers, @swapkit/toolboxes/evm|solana|utxo, @metamask/connect-multichain, wallet-extensions/evm-extensions) with partial namespaces and never restore them. mock.module is process-global, so whenever the dependency graph shares one copy of a module across packages, later test files import the crippled mock — this was both the phantom "Export named 'AbstractSigner' not found in ethers" CI failure on the GitHub runners and the order-dependent evm-extensions/keystore flakes. Each file now snapshots the real module and restores it in afterAll. Full suite: 106/106. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Drop the root
@swapkit/cosmos-signer: 0.1.0override — the stopgap from chore: adopt SwapKit SDK 5.0.0 across all @swapkit/* dependencies #138 while toolboxes'cosmos-signer@0.2.0peer was unpublished. 0.2.0 is on npm now; the lockfile re-resolves to it (exact peers: noble/scure 2.2.0, cosmjs-types 0.11.0).Fix cross-file
mock.moduleleaks in four test files — and with them, both long-standing CI mysteries.mock.modulereplaces a module's whole export namespace process-wide; these files installed partial mocks (e.g.ethersreduced to{BrowserProvider},toolboxes/evmto a 2-method stub) and never restored them. Whenever the dependency graph shares one copy of the module across workspace packages — GH runners always; locally after this re-resolution — later test files import the crippled mock:Export named 'AbstractSigner' not found in ethersfailures that killed the CI test step on chore: adopt SwapKit SDK 5.0.0 across all @swapkit/* dependencies #138/fix(build): unblock Release on bun 1.4.0 (cjs splitting + setup-repo bun pin) #139 (unreproducible locally at the time because local installs still had per-package copies),evm extensions … re-adds connected chains/ keystore HYPE derivation flakes.Each file now snapshots the real module and restores it in
afterAll.Verification
bun 1.3.13:
build:ci✅ ·type-check:ci0 errors ✅ ·bun test106/106 ✅ (previously 105/1 with the leak). No changeset: root-manifest + test-only changes, no published-package dep ranges touched.🤖 Generated with Claude Code