[RELEASE] chore(deps): sync tnt-core ABIs + modernize deps to prod-ready#3276
Conversation
Sync ABIs/fixtures from tnt-core HEAD (61 commits past the v0.13.0 pin, including 1 critical + 21 high security fixes). Only blueprintServiceManager changed, additively: +onBinaryVersionPublished, +onOperatorBinaryAcked from the multi-arch binary-publish work. Dependency modernization (all gates green, zero app code changes needed): - @tangle-network: ui 1->4, sandbox-ui 0.15->0.40, blueprint-ui 0.1->0.5, brand 0.3->0.5 (company packages, APIs stayed compatible) - @PolkaDot: whole suite 13->14 coherently (api/types 14.3.1, keyring/util/util-crypto 14.0.3) + resolutions updated; scoped to legacy migration-claim flows - ~50 within-major bumps: radix, tanstack, framer, react-router 7.18, react-hook-form, swc, postcss, prettier, eslint-plugin-import, wagmi, etc. Held at known-good versions (each broke a gate when bumped): - viem 2.41.2: ox 0.14.29 ships .ts BigInt needing tsconfig target ES6->ES2020 - connectkit 1.9.1: 1.9.2 removed the enableFamily option - typescript 5.8.3: 5.9 Uint8Array generic churn across WebCrypto callers - vitest 3.1.x + vite-plugin-node-polyfills 0.23.0: 3.2 / 0.23.1 regressed Node 'assert' resolution in the test environment Cleanups: - fix pre-existing typecheck break in eslint.config.js (react-hooks v7 readiness rules were typed as bare strings, rejected by flat-config) - delete dead apps/tangle-cloud/src/stores/roleStore.tsx (zero references, was also breaking lint via react-refresh/only-export-components) - drop Node 'assert' import from a browser-shipping util (assertAddressBy) Gates: typecheck, lint (0 errors), 197 tests, build tangle-dapp + tangle-cloud all green. e2e wallet-flow suite not run (env-gated: needs LLM key + local chain + wallet extension). Big framework majors (React 19, Tailwind 4, Vite 8, Storybook 10, Nx 23, TS 6, vitest 4, recharts 3, zod 4, wagmi 3) deferred to dedicated PRs.
prettier 3.8 changes formatting rules and drifts 28 files repo-wide; the mechanical reformat belongs in a dedicated chore PR, not a deps sweep. Held at the version the codebase is currently formatted against so the pre-push format:check hook stays green.
tangletools
left a comment
There was a problem hiding this comment.
✅ Auto-approved PR — f462af16
Blanket team auto-approval is enabled for this reviewer service.
The full PR reviewer audit still runs separately and will publish findings if it detects issues.
tangletools · auto-approval · reason: blanket_auto_approve · 2026-06-21T16:33:05Z
tangletools
left a comment
There was a problem hiding this comment.
🟡 Value Audit — sound-with-nits
| Verdict | sound-with-nits |
| Concerns | 3 (3 weak-concern) |
| Heuristic | 0.0s |
| Duplication | 0.0s |
| Interrogation | 123.7s (2 bridge agents) |
| Total | 123.7s |
💰 Value — sound-with-nits
A coherent dependency/ABI hygiene sweep: syncs tnt-core ABIs, modernizes prod deps, greens typecheck/lint, and deletes dead code, with one minor incomplete cleanup.
- What it does: Synchronizes the dapp with latest tnt-core by adding two new ABI functions (
onBinaryVersionPublishedat libs/tangle-shared-ui/src/abi/blueprintServiceManager.ts:367 andonOperatorBinaryAckedat :548); bulk-upgrades package.json dependencies across Polkadot 13→14, @tangle-network/* packages, radix, wagmi, and ~50 others; fixes a typecheck failure in eslint.config.js by inlining the v7 hooks rea - Goals it achieves: Keeps the UI's contract surface in sync with the protocol, pulls in security and compatibility fixes, restores a green typecheck/lint baseline on develop, and removes dead/lint-breaking code without changing app business logic.
- Assessment: Good change on its merits. It is narrow, uses the existing
sync:tnt-core-assetsscript path (scripts/sync-tnt-core-assets.mjs, referenced in package.json:38), pins back upgrades that broke gates, and removes genuinely dead code (grep found zero references toroleStore/useRoleStore). The only material nit is that the Node-assert removal is limited to one file while sibling address utilities - Better / existing approach: none for the overall sweep. For the assert cleanup, the codebase already has many browser-shipping address utilities importing Node
assert(assertEvmAddress.ts:1, assertSolanaAddress.ts:1, assertSubstrateAddress.ts:1, assertBytes32.ts:1, plus broader browser code). A shared tiny browser-safe assert helper inlibs/ui-components/src/utilswould make the cleanup consistent, but the one-file fix i - Model: opencode/kimi-for-coding/k2p7
- Bridge attempts: 1
🎯 Usefulness — sound-with-nits
Coherent deps-and-sync PR with green-gated package bumps, real dead-code removal, and a correct browser-safety fix; only weak notes around an inconsistent assert-purge and the pre-existing zero-importer status of the synced ABI file.
- Integration: The dep bumps integrate through the existing yarn lockfile and the full build is the consumer.
assertAddressBy.tsis re-exported vialibs/ui-components/src/utils/index.ts:2with its throwing contract preserved.roleStore.tsxdeletion is safe —rgfor any of its exports returns nothing. The two new entries inblueprintServiceManager.tsare produced by the existing auto-gen script `scripts - Fit with existing patterns: Follows established patterns cleanly. ABI sync is the existing
sync-tnt-core-assets.mjspipeline;as consttyping matches every other file inlibs/tangle-shared-ui/src/abi/. Theassert->throw new Errorrewrite keeps the public signature and message. Inlining thereactCompilerReadinessRulesobject into the config array is a pure mechanical move that resolves the typed-as-bare-string t - Real-world viability: Holds up on the realistic paths. The assert rewrite throws on the same predicate with the same message — call sites see no behavior delta. The new ABI entries are pure additive ABI fragments typed
as constso viem/wagmi consumers get correct inference if/when wired. The deletedroleStore.tsxwas zustand-persisted; no consumer touches the persisted key, so even a stale localStorage entry from p - Model: opencode/zai-coding-plan/glm-5.2
- Bridge attempts: 1
🎯 Usefulness Audit
🟡 Node-assert purge is one-of-seven; stated goal partially served [problem-fit] ``
PR body frames dropping
import assert from 'assert'fromassertAddressBy.tsas a browser-safety fix, but six sibling files in the sameutils/directory still import Node'sassert:assertSubstrateAddress.ts,assertBytes32.ts,assertEvmAddress.ts,assertSolanaAddress.ts,toEvmAddress.ts,calculateBnRatio.ts(grep-confirmed). The change is correct for the file it touches; the framing oversells it. Either scope the commit message down or sweep the siblings in a follow-up.
🟡 Synced ABI file has zero importers; new events have no caller today [integration] ``
rgforblueprintServiceManagerreturns onlyscripts/sync-tnt-core-assets.mjsand the file itself — no TS module imports the default export. The binary-version flow it would seemingly serve (libs/tangle-shared-ui/src/data/blueprints/useBinaryVersions.ts) reads viatangleBinaryUpgradeinstead. This is a pre-existing condition this PR doesn't worsen — the file was already unreferenced. The newonBinaryVersionPublished/onOperatorBinaryAckedevents mirror theBinaryVersionshape alr
💰 Value Audit
🟡 Node assert cleanup is incomplete [maintenance] ``
The PR drops
import assert from 'assert'only inlibs/ui-components/src/utils/assertAddressBy.ts:1. Sibling address guards in the same directory still import Nodeassert(assertEvmAddress.ts:1, assertSolanaAddress.ts:1, assertSubstrateAddress.ts:1, assertBytes32.ts:1), so the browser bundle still carries the same polyfill/dependency for those paths. A shared small assert helper would finish the job, but this does not block the PR's primary goal.
What this audit checks
It judges the change on its merits — not whether it was tasked out in an issue. Unticketed, fast-moving work is fine; the question is whether the change is good and whether a better or existing approach should be used instead.
| Pass | What it asks |
|---|---|
| Heuristic | Vague title? Whitespace-only or cruft-bearing diff? (content signals only) |
| Duplication | Do added function/class names already exist elsewhere in the repo? |
| Value Audit | What does it do? What goal does it achieve? Is it good? Better architecture or already-exists? |
| Usefulness Audit | Does it integrate and fit? Will it hold up in real use and actually get used? |
Findings are concerns, not blocks — the human reviewer decides what to do with them.
❌ Needs Work —
|
| opencode-kimi | glm | deepseek | aggregate | |
|---|---|---|---|---|
| Readiness | 0 | 39 | 32 | 0 |
| Confidence | 85 | 85 | 85 | 85 |
| Correctness | 0 | 39 | 32 | 0 |
| Security | 0 | 39 | 32 | 0 |
| Testing | 0 | 39 | 32 | 0 |
| Architecture | 0 | 39 | 32 | 0 |
Full multi-shot audit completed 5/5 planned shots over 5 changed files. Global verifier still owns final merge decision. | Full multi-shot audit completed 5/5 planned shots over 5 changed files. Global verifier still owns final merge decision. | Full multi-shot audit completed 5/5 planned shots over 5 changed files. Global verifier still owns final merge decision.
Blocking
🔴 HIGH @polkadot/util and util-crypto dual-version shipping (v13 + v14) — package.json
extension-dapp@0.58.7 (line: pinned exact) declares its own dependency on @polkadot/util@^13.4.3 and @polkadot/util-crypto@^13.4.3. The app-level dependencies bump both to ^14.0.3 (lines with @polkadot/util, @polkadot/util-crypto). Yarn cannot deduplicate: the lockfile contains 4 v13 entries + 2 v14 entries for each. Impact: ~400KB+ of duplicated crypto/util code in the production bundle, and any object created by extension-dapp's v13 util (e.g. a Keypair) passed to app code importing v14 types will fail instanceof checks. Fix: either add resolutions for @polkadot/util and @polkadot/util-crypto to force v14, or bump extension-dapp to a version compatible with v14 (0.58.x may not exist; check upstream).
🔴 HIGH @storybook/addon-themes 10.x requires Storybook 10.x but project uses 8.x — package.json
package.json:160 sets
@storybook/addon-themes: ^10.4.6while line 223 setsstorybook: ^8.6.18and all other @storybook/* deps are ^8.6.x. npm shows @storybook/addon-themes@10.4.6 peerDependencies requirestorybook: ^10.4.6.yarn install --immutablewarns: "storybook is listed by your project with version 8.6.18, which doesn't satisfy what @storybook/addon-themes and other dependencies request (but they have non-overlapping ranges!)." Risk: Storybook build/runtime failure because the addon is for a different major version.
🔴 HIGH @tangle-network/blueprint-ui peer deps conflict with React 18 / wagmi 2 — package.json
package.json:103 sets
@tangle-network/blueprint-ui: ^0.5.3. npm shows blueprint-ui@0.5.3 peerDependencies requirereact: ^19.0.0,react-dom: ^19.0.0,wagmi: ^3.3.0,@nanostores/react: ^0.7.0,nanostores: ^0.10.0. The project listsreact: ^18.3.1(line 122),react-dom: ^18.3.1(line 124),wagmi: ^2.19.5(line 137),@nanostores/react: ^1.1.0(line 70), `nan
🔴 HIGH @vitest/ui 4.x incompatible with vitest 3.x — package.json
package.json:191 sets
@vitest/ui: ^4.1.9while line 240 setsvitest: ~3.1.1. npm shows @vitest/ui@4.1.9 peerDependencies requirevitest: 4.1.9.yarn install --immutablewarns: "@vitest/ui is listed by your project with version 4.1.9, which doesn't satisfy what vitest requests (3.1.4)" and "vitest is listed by your project with version 3.1.4, which doesn't satisfy what @vitest/ui and other dependencies request (but they have non-overlapping ranges!)." Risk: broken test UI / reporter integration.
🔴 HIGH Missing required peer @mysten/sui for @mysten/dapp-kit — package.json
package.json:69 sets
@mysten/dapp-kit: ^1.1.1. npm shows @mysten/dapp-kit@1.1.1 peerDependencies require@mysten/sui: ^2.19.0. This dependency is absent from package.json.yarn install --immutablereports YN0002: "tangle-monorepo@workspace:. doesn't provide @mysten/sui (p5f64f), requested by @mysten/dapp-kit." Risk: runtime import failures in Sui wallet code paths.
🔴 HIGH Missing required peer @tangle-network/agent-interface for sandbox-ui — package.json
package.json:105 sets
@tangle-network/sandbox-ui: ^0.40.0. npm shows sandbox-ui@0.40.0 peerDependencies require@tangle-network/agent-interface: ">=0.10.0 <1.0.0"and it is not marked optional. This dependency is absent from package.json and from yarn.lock.yarn install --immutablereports YN0002: "tangle-monorepo@workspace:. doesn't provide @tangle-network/agent-interface (pb24aa), requested by @tangle-network/sandbox-ui." Risk: runtime import failures when sandbox-ui code tries to import the peer.
🔴 HIGH Polkadot package fragmentation: types 14.3.1 and 15.9.1 both installed, util/keyring major mismatch — package.json
package.json:58-60 resolutions force
@polkadot/api: ^14.0.0and@polkadot/api-derive: ^14.0.0, and direct deps set@polkadot/types: ^14.0.0,@polkadot/util: ^14.0.3,@polkadot/keyring: ^14.0.3,@polkadot/util-crypto: ^14.0.3. However, @polkadot/api@14.3.1 itself depends on@polkadot/keyring: ^13.2.3,@polkadot/util: ^13.2.3,@polkadot/util-crypto: ^13.2.3(npm metadata). Meanwhile @polkadot/apps-config@0.153.1 and @polkadot/extension-inject@0.58.7 depend on@polkadot/types: ^15.9.1and@polkadot/util: ^13.4.3. yarn.lock contains both@polkadot/types@14.3.1and@polkadot/types@15.9.1, plus both util/keyring/util-crypto 13.x and 14.x.yarn install --immutablewarns: "@polkadot/util is listed by your project with version 14.0.3, which doesn't satisfy what @PolkaDot
🔴 HIGH @swc/core 1.11.31 does not satisfy @swc-node/register peer requirement — yarn.lock
yarn.lock resolves the workspace's @swc/core to 1.11.31 (yarn.lock:15040), but @swc-node/register@1.11.1 (via the lockfile) declares
peerDependencies: { '@swc/core': '^1.13.3' }.yarn explain peer-requirementsreportsp51819 → ✘ tangle-monorepo@workspace:. provides @swc/core@npm:1.11.31 [1ce20] to @swc-node/register@npm:1.11.1 [1ce20] and 5 other dependencies. Impact: SWC-based registration/compilation may silently fall back or fail. Fix: bump @swc/core to ^1.13.3 or downgrade @swc-node/register.
🔴 HIGH @vitest/ui 4.1.9 is incompatible with vitest 3.1.4 — yarn.lock
yarn.lock resolves @vitest/ui to 4.1.9 (yarn.lock:16781) which declares
peerDependencies: { vitest: 4.1.9 }, while vitest is resolved to 3.1.4 (yarn.lock:34638).yarn explain peer-requirementsreports this as unmet:p41b8f → ✘ tangle-monorepo@workspace:. provides @vitest/ui@npm:4.1.9 [1ce20] to vitest@npm:3.1.4 [1ce20]. Impact: the Vitest UI will fail to load or behave incorrectly. Fix: align @vitest/ui with vitest 3.x (e.g. ^3.1.1) or upgrade vitest to 4.x.
Other
🟠 MEDIUM @polkadot/keyring dual-version: API v14 internally uses keyring v13 — package.json
The resolved @polkadot/api@14.3.1 itself depends on @polkadot/keyring@^13.2.3 (resolved to 13.5.9), while the app explicitly depends on @polkadot/keyring@^14.0.3. The API's internal keyring operations use v13, but app code importing keyring directly gets v14. If the app passes a v14 Keyring instance to an API method expecting a v13 one, instanceof guards will fail. This is a known transitional state in @polkadot/api v14 — the API itself hasn't migrated its internal keyring dependency yet. Low immediate risk if the app doesn't pass keyring objects to API, but fragile. Fix: track @polkadot/api releases for the internal keyring bump, or add a resolution for @polkadot/keyring to force v14 if v14 is backwards-compatible with v13 API types.
🟠 MEDIUM @swc/core ~1.11.31 too old for @swc-node/register ^1.11.1 — package.json
package.json:173 sets
@swc/core: ~1.11.31and line 171 sets@swc-node/register: ^1.11.1. npm shows @swc-node/register@1.11.1 depends on@swc-node/core: ^1.14.1, whose peerDependencies require@swc/core: ">= 1.13.3".yarn install --immutablewarns: "@swc/core is listed by your project with version 1.11.31, which doesn't satisfy what @swc-node/core (via @swc-node/register) and other dependencies request (^1.13.3)." Risk: SWC-based builds or tests may fail or fall back unexpectedly.
🟠 MEDIUM Storybook addon-essentials version lag behind core packages — package.json
@storybook/addon-essentials is pinned at exact 8.6.14 while all 13 other @storybook/* packages are bumped to ^8.6.18. The addon-essentials meta-package resolves its sub-addons (actions, backgrounds, controls, docs) at 8.6.14, while core packages (channels, components, core-events, manager-api, preview-api, theming) are at 8.6.18. Storybook historically enforces strict version alignment across its package family; a 8.6.14→8.6.18 mismatch between the channel API used by addons and the manager/preview can cause runtime errors in story rendering or addon panels. Fix: bump addon-essentials to ^8.6.18 to match the rest of the storybook fleet.
🟠 MEDIUM e2e wallet-flow suite explicitly skipped despite polkadot 13→14 + tangle-ui 1→4 majors — package.json
Commit a4e2a2e message states: 'e2e wallet-flow suite not run (env-gated: needs LLM key + local chain + wallet extension)'. The PR bumps @polkadot/api/types 13.2.1→14.3.1 (a MAJOR Substrate API migration that changes type codecs, extrinsic signing surfaces, and query result shapes), @polkadot/keyring/util/util-crypto 13.4.3→14.0.3, and @tangle-network/ui 1.0.1→4.1.0 (3 major versions). Unit tests (197) + typecheck + lint + build are green per commit, but wallet signing, balance reads, and tx submission are exactly the surfaces most likely to break on a polkadot major bump and are precisely what the wallet-flow suite exists to catch. Impact: a signing or balance-display regression could land undetected. Fix: run
yarn test:wallet-flows:staking:local(or at minimum `test:staking:local-relea
🟠 MEDIUM @bigmi/react pinned at 0.6.3 while client/core resolve to 0.6.5 — yarn.lock
package.json pins
@bigmi/reactto0.6.3(no caret). yarn.lock shows@bigmi/react@npm:0.6.3(yarn.lock:2096) depends on@bigmi/client: ^0.6.3and@bigmi/core: ^0.6.3, both of which resolve to 0.6.5 (yarn.lock:2067, 2080). This skews the bigmi suite: React integration runs against newer client/core binaries. Impact: potential API mismatch in the Bitcoin wallet connector. Fix: unpin @bigmi/react to^0.6.5or verify 0.6.3 React layer is compatible with 0.6.5 core.
🟠 MEDIUM @reown/appkit pinned to a prerelease tag (1.8.17-wc-circular-dependencies-fix.0) — yarn.lock
@reown/appkit@npm:1.8.17-wc-circular-dependencies-fix.0 (and 9 sibling @reown/appkit-* packages at the same tag) is a non-stable prerelease that the lockfile now resolves. The tag name suggests it is a temporary build to work around a WalletConnect circular-dependency bug, not an official release. Reown ships a 1.x stable line; running a prerelease wallet library in a production dApp means accepting instability, possible re-publish/repudiation, and no semver guarantees. Lockfile evidence: yarn.lock:12093-15310 contain both 1.7.8 (stable) and 1.8.17-wc-circular-dependencies-fix.0 (prerelease) blocks side by side. Impact: wallet connection surface carries prerelease risk. Fix: confirm with Reown when 1.8.17 stable ships and repoint the workspace requirement; if the WC circular-dep bug is blo
🟠 MEDIUM Four zustand versions in the dependency tree — yarn.lock
yarn.lock resolves zustand to 5.0.0 (via @wagmi/core, yarn.lock:37732), 5.0.3 (via @coinbase/wallet-sdk/@base-org/account, yarn.lock:37753), 5.0.9 (via porto, yarn.lock:37774), and 5.0.14 (direct + @bigmi + @mysten/dapp-kit, yarn.lock:37795).
yarn why zustandconfirms all four. Because zustand relies on React context for store sharing, multiple copies can break state subscriptions. Impact: subtle state-management bugs. Fix: add a yarn resolution forzustandor align dependents.
🟠 MEDIUM Three distinct viem versions in the dependency tree — yarn.lock
yarn.lock resolves viem to 2.41.2 (direct dep, yarn.lock:36623), 2.53.1 (transitive via @reown/appkit@1.8.17-wc-circular-dependencies-fix.0, yarn.lock:36644), and 2.23.2 (transitive via @walletconnect/utils 2.21.0/2.21.1, yarn.lock:36602).
yarn why viemconfirms all three are active. viem is a singleton-style Ethereum library; multiple copies can cause type mismatches and wagmi connector bugs. Impact: runtime wallet/Ethereum interaction issues. Fix: add a yarn resolution to enforce a single viem version compatible with the rest of the tree.
🟠 MEDIUM Two vite versions active (6.2.7 and 6.4.3) — yarn.lock
yarn.lock resolves the workspace's vite to 6.2.7 (yarn.lock:36808, matching
~6.2.6), while vitest/vite-node pull in vite 6.4.3 (yarn.lock:36753).yarn why viteconfirms both. Impact: plugin API surface and build/dev behavior can diverge between the app build and test runner. Fix: align vite ranges so vitest uses the same vite as the workspace, or accept via resolution.
🟡 LOW Named constant removed; intent now lives only in comment — eslint.config.js
Lines 47-59: the previous
reactCompilerReadinessRulesconst gave this 14-rule block a self-documenting name; after inlining, the only signal that these are React-Compiler-readiness diagnostics is the comment at lines 44-46. No behavior change. Optional nit: keep as a localconstinsidetseslint.config(...)if naming intent is desired, or leave as-is since the comment is accurate. Not blocking.
🟡 LOW ABI is unused by any application code — libs/tangle-shared-ui/src/abi/blueprintServiceManager.ts
grep confirmed 0 importers of this ABI outside scripts/. The file is auto-generated and never consumed. The new onBinaryVersionPublished and onOperatorBinaryAcked entries — adding 73 lines — have zero runtime surface. Not a bug, but worth understanding: is this ABI still needed, or should the sync script be updated to skip unused ABIs? The functional equivalent lives in tangleBinaryUpgrade.ts (imported by 4 files in libs/ and apps/).
🟡 LOW No checksum test asserting generated ABI matches source IBlueprintServiceManager.json — libs/tangle-shared-ui/src/abi/blueprintServiceManager.ts
The file is marked AUTO-GENERATED (line 1) and produced by scripts/sync-tnt-core-assets.mjs:24-38 via JSON.stringify, but no test verifies the committed .ts file is in sync with tnt-core's IBlueprintServiceManager.json. A drift (e.g., regenerating with a stale tnt-core checkout) would silently ship an ABI that doesn't match the deployed contract. Not introduced by this PR — pre-existing. Fix: add a snapshot test in libs/tangle-shared-ui/src/abi/tests/ that re-derives the expected content from the JSON source (when TNT_CORE_DIR is available) or at least asserts the two new function names exist with the expected input arity.
🟡 LOW Error class changes from AssertionError to plain Error — libs/ui-components/src/utils/assertAddressBy.ts
Lines 7-11: Node's
assert()throwsAssertionErrorwitherr.code === 'ERR_ASSERTION'; the new code throws a plainError. Any downstream consumer (external package user) catching by class or code would see different error metadata. Impact is negligible: I grepped the repo and found zero callers ofassertAddressBybeyond the barrel re-export, and all in-repo catch sites (e.g.,toBigInt.ts:20) useerror instanceof Error, which still matches. No fix required for this shot; flagging only so an external consumer doinginstanceof assert.AssertionErroris aware.
🟡 LOW Migration is piecemeal — 6 sibling utils still import assert module — libs/ui-components/src/utils/assertAddressBy.ts
Only
assertAddressBy.tswas migrated in this shot.assertEvmAddress.ts,assertSolanaAddress.ts,assertBytes32.ts,assertSubstrateAddress.ts,toEvmAddress.ts,calculateBnRatio.ts, andSlidingNumber.tsxstillimport assert from 'assert'(verified via grep). The stated goal (presumably removing the Node-builtin dependency) is only partially achieved inlibs/ui-components. Not a blocker for this shot — those files are explicitly out of scope — but the inconsistency is worth a follow-up to fully realize the browser-safety benefit.
🟡 LOW No test coverage for assertAddressBy — libs/ui-components/src/utils/assertAddressBy.ts
No
assertAddressBy.test.tsexists. The function is a thin generic wrapper over a type-guard predicate; a 2-case test (valid → returns T, invalid → throws with expected message) would lock the contract. Pre-existing gap, not introduced by this diff, but the behavior change in error class makes now a natural time to add it.
🟡 LOW No tests for assertAddressBy utility — libs/ui-components/src/utils/assertAddressBy.ts
No test file exists for assertAddressBy (or any util in libs/ui-components/src/utils/). The function has zero downstream consumers, which makes it effectively dead code — it could break silently. The change itself is correct but untested. Pre-existing condition, not introduced by this diff.
🟡 LOW No unit tests for assertAddressBy — libs/ui-components/src/utils/assertAddressBy.ts
There is no test coverage for the success path (guard returns true, address is returned as T) or the failure path (guard returns false, an Error is thrown with the expected message). While the change is behaviorally equivalent to the previous
assertcall, missing tests leave regressions in guard integration undetected. Add a spec file or test cases for both paths.
🟡 LOW @bigmi/react and connectkit exact-version pins lose patch updates — package.json
@bigmi/react changed from ^0.6.3 to 0.6.3 (caret removed, exact pin) and connectkit from ^1.9.1 to 1.9.1. These exact pins prevent any patch-level bugfix or security update from being adopted on yarn install. The lockfile already freezes versions for reproducibility, so the package.json change signals intent to block even intentional upgrades. If this is a deliberate freeze due to a known-bad upstream release, document it. Otherwise restore the caret for patch flexibility.
🟡 LOW @storybook/addon-themes 10.4.6 requires storybook ^10.4.6 but repo pins storybook ^8.6.18 — package.json
Line 160: @storybook/addon-themes bumped ^10.3.5 → ^10.4.6. npm confirms its peerDependency is {storybook: '^10.4.6'}, but line 223 pins storybook ^8.6.18 (the entire 8.6.x ecosystem). This is a peer-dep MISMATCH that produces install warnings and risks the addon targeting storybook-10 APIs that storybook-8 does not expose. This is PRE-EXISTING (10.3.5 also required storybook ^10.3.5), so the PR does not introduce the mismatch — only bumps within the already-mismatched 10.x line. Impact: storybook dev tooling may degrade; production build unaffected. Fix: either pin addon-themes to
🟡 LOW @types/lodash ^4.17.24 lags lodash ^4.18.1 — new lodash APIs untyped — package.json
Line 118 bumps lodash ^4.17.21 → ^4.18.1; line 182 bumps @types/lodash ^4.17.16 → ^4.17.24. npm confirms @types/lodash latest is 4.17.24 (no 4.18.x types published). If lodash 4.18.0/4.18.1 introduced new public APIs, they will be untyped and surface as implicit-any errors under the repo's strict tsconfig. Likely low-impact since 4.18.x appears to be maintenance fixes, but unverified. Fix: check lodash 4.18.0/4.18.1 changelog for new exports; if any, add local module augmentation or wait for @types/lodash 4.18.x.
🟡 LOW Multiple viem resolutions in lockfile (2.23.2 + 2.41.2 + >=2.37.9) — bundle bloat and potential type skew — package.json
package.json tightened viem from ^2.37.0 to ~2.41.2 (line 136). yarn.lock contains three distinct viem resolutions: 'viem@npm:2.23.2' (separate resolution), 'viem@npm:~2.41.2 / ^2.41.2 / ^2.31.7 / ^2.27.2 / ^2.21.26 / ^2.1.1 / >=2.29.0 → 2.41.2' (main), and 'viem@npm:>=2.37.9' (third resolution). The 2.23.2 entry means at least one transitive consumer pins an old viem, so two viem copies ship in the bundle. Impact: ~extra ~150KB gzipped, and any consumer that re-exports viem types across the boundary (e.g. wagmi helpers) may see 'type X is not assignable to type X' errors. The ~2.41.2 hold itself is correctly documented (ox 0.14.29 BigInt ES2020 churn). Fix: identify the consumer pinni
🟡 LOW Two @polkadot/keyring copies (14.0.3 top-level + 13.5.9 via api@14.3.1) — cross-boundary instanceof will fail — package.json
package.json pins @polkadot/keyring ^14.0.3 (line 78), @polkadot/util ^14.0.3 (line 81), @polkadot/util-crypto ^14.0.3 (line 82) at top level. But @polkadot/api@14.3.1 (what the ^14.0.0 spec resolves to in yarn.lock) declares dependencies '@polkadot/keyring: ^13.2.3', '@polkadot/util: ^13.2.3', '@polkadot/util-crypto: ^13.2.3' (verified via
npm view @polkadot/api@14.3.1 dependencies). Since ^13.2.3 does not satisfy ^14.0.3, yarn installs BOTH: lockfile shows '@polkadot/keyring@n
🟡 LOW @reown/appkit pre-release dist-tag included — yarn.lock
yarn.lock resolves
@reown/appkitto1.8.17-wc-circular-dependencies-fix.0(verified on npm as a real published prerelease). This brings in viem 2.53.1 and creates the duplicate-viem issue above. Impact: relies on a non-stable release line. Fix: prefer a stable @reown/appkit release if available, or document why this prerelease is required.
🟡 LOW @tangle-network/agent-interface declared as required peer of @tangle-network/sandbox-ui@0.40.0 but absent from lockfile — yarn.lock
yarn.lock:15264-15268 lists @tangle-network/sandbox-ui@0.40.0 peerDependencies including '@tangle-network/agent-interface: >=0.10.0 <1.0.0'. That package is NOT listed in peerDependenciesMeta (so yarn treats it as required) and a grep for '"@tangle-network/agent-interface@' across yarn.lock returns zero resolutions. This means yarn install would emit a peer-dep warning and any code path inside sandbox-ui that imports from @tangle-network/agent-interface would crash at runtime if the host app does not provide it. Impact: silent peer-dep violation that surfaces only when the relevant sandbox-ui code runs. Fix: either add @tangle-network/agent-interface to the workspace root dependencies (in package.json, out of this shot's scope) or have sandbox-ui mark it optional in peerDependenciesMeta.
🟡 LOW @tangle-network/ui v1→v4 and sandbox-ui v0.15→v0.40 carry runtime risk — yarn.lock
yarn.lock:34655-34659 — Multiple @tangle-network internal packages bumped across major versions (ui: ^1.0.1→^4.1.0, sandbox-ui: ^0.15.3→^0.40.0, blueprint-ui: ^0.1.2→^0.5.3, brand: ^0.3.0→^0.5.0). Lockfile resolution is consistent with package.json but these bumps may change component APIs. The full PR's source changes should be audited for compatibility.
🟡 LOW Exact-version pins reduce auto-patch security updates — yarn.lock
yarn.lock:49 — @bigmi/react pinned from ^0.6.3 to exact 0.6.3, connectkit pinned from ^1.9.1 to exact 1.9.1. These pins prevent automatic patch-version updates that could deliver security fixes for sub-dependencies. This is a deliberate architectural choice (the commit message says 'modernize deps to prod-ready') but means manual intervention is needed for future security patches.
🟡 LOW Major @polkadot/api bump v13→v14 needs runtime validation — yarn.lock
yarn.lock:2065-2075 — @polkadot/api, @polkadot/types, @polkadot/util, @polkadot/util-crypto all bumped from ^13.x to ^14.0.0. This is a major version change with potential breaking API changes. The lockfile resolves this correctly but the diff here does not prove the application code was migrated. Verdict depends on the other changed source files in the full PR.
🟡 LOW Three viem versions and six ox versions coexist (bundle bloat + runtime type-mismatch risk) — yarn.lock
yarn.lock now resolves viem@2.23.2 (pinned by @walletconnect/utils@2.21.0/2.21.1), viem@2.41.2 (workspace default), and viem@2.53.1 (pulled in by @reown/appkit@1.8.17-wc-circular-dependencies-fix.0 via the '>=2.37.9' range). Similarly, ox is resolved at 0.6.7, 0.6.9, 0.9.3, 0.9.6, 0.9.17, and 0.14.29. Each viem version pulls its own @noble/curves, @noble/hashes, abitype, isows, ws. Impact: (1) bundle size increase; (2) if application code passes a viem object (e.g., a WalletClient or PublicClient) from one package into another that resolved a different viem copy, instanceof checks and type narrowing can silently fail. This is a well-known footgun in viem-based stacks. Fix: nothing to change in yarn.lock itself, but verify with
yarn dedupe viem oxwhether the ranges can be collapsed; the
🟡 LOW lodash bumped to 4.18.1 from ^4.17.21 baseline; @types/lodash also bumped — yarn.lock
The workspace requirement moved from 'lodash: npm:^4.17.21' to 'lodash: npm:^4.18.1' (yarn.lock:9178-9184 + workspace metadata block at yarn.lock:34630+). Verified against https://registry.npmjs.org/lodash/4.18.1: published by jdalton (John-David Dalton, the original lodash maintainer), MIT, signed with the standard npm signing key. This is a real first-party release, not a supply-chain attack. @types/lodash was also bumped 4.17.16 -> 4.17.24 to match. No code action required, but reviewers should be aware lodash 4.18.x is newer than the long-stable 4.17.21 (frozen since Feb 2021) and may behave subtly differently; if the dApp uses lodash in billing/precision paths, smoke-test those flows.
tangletools · 2026-06-21T16:50:58Z · trace
tangletools
left a comment
There was a problem hiding this comment.
❌ 9 Blocking Findings — f462af16
Full multi-shot audit completed 5/5 planned shots over 5 changed files. Global verifier still owns final merge decision. | Full multi-shot audit completed 5/5 planned shots over 5 changed files. Global verifier still owns final merge decision. | Full multi-shot audit completed 5/5 planned shots over 5 changed files. Global verifier still owns final merge decision.
Full immutable report for this review: trace
Summary comment for this run: full summary
tangletools · 2026-06-21T16:50:58Z · immutable trace
…onsistency Addresses the bot review's blocking peer-dependency findings. Tree is now fully peer-clean (zero YN0002/YN0060 warnings, down from 12). Reverted bumps that caused un-dedupable fragmentation / unsatisfiable peers: - @PolkaDot 13->14 reverted to ^13: api@14 internally pins keyring/util/util-crypto to ^13.2.3, so bumping them to ^14 shipped both majors (instanceof failures across the boundary). Coherent v13 restored. - @tangle-network/{ui,brand,sandbox-ui,blueprint-ui} reverted to develop's set: blueprint-ui 0.5 requires React 19 / wagmi 3; sandbox-ui 0.40 requires @tangle-network/agent-interface + @xyflow/react peers, and is peer-coupled to ui (0.15 needs ui@^1, 0.40 needs ui@^4). These majors are a coordinated React-19 migration, not a deps sweep. - @swc-node/register reverted to ^1.10.10 (its @swc-node/core transitive needs @swc/core >=1.13.3); @swc/core bumped to ^1.13.3 to satisfy it. - @storybook/addon-themes realigned to ^8.6.18 (was mismatched at 10.x against storybook 8.x); addon-essentials bumped to ^8.6.18 to match. - @vitest/ui aligned to ~3.1.1 to match vitest 3.x. - @bigmi/react unpinned to ^0.6.5 to align with its client/core 0.6.5. Removed: - @mysten/dapp-kit (zero source imports anywhere — dead dep; also removes its unsatisfiable @mysten/sui peer requirement). Completed the browser-safe assert migration flagged as piecemeal: - new shared libs/ui-components/src/utils/assert.ts (throws Error, carries an `asserts condition` signature so callers keep type-narrowing) - migrated assertAddressBy, assertBytes32, assertEvmAddress, assertSolanaAddress, assertSubstrateAddress, toEvmAddress, calculateBnRatio, and SlidingNumber off Node's `assert` built-in. Gates: typecheck, lint, 197 tests, build dapp+cloud all green.
tangletools
left a comment
There was a problem hiding this comment.
✅ Auto-approved PR — 84171e50
Blanket team auto-approval is enabled for this reviewer service.
The full PR reviewer audit still runs separately and will publish findings if it detects issues.
tangletools · auto-approval · reason: blanket_auto_approve · 2026-06-21T18:14:26Z
Review findings addressed —
|
| # | Finding | Resolution |
|---|---|---|
| 1, 7 | @PolkaDot util/crypto/keyring dual v13+v14 | Reverted whole suite to ^13. @polkadot/api@14.3.1 internally pins keyring/util/util-crypto to ^13.2.3 (npm-verified), so bumping them to ^14 shipped both majors and broke cross-boundary instanceof. Coherent v13 restored. |
| 2 | addon-themes 10.x vs storybook 8.x | Aligned @storybook/addon-themes to ^8.6.18 (the 8.x line exists) to match the storybook 8 fleet. |
| 3 | blueprint-ui 0.5 needs React 19 / wagmi 3 | Reverted @tangle-network/blueprint-ui to ^0.1.2 (0.1.2 peers are satisfied by React 18 / wagmi 2). |
| 4, 9 | @vitest/ui 4.x vs vitest 3.x | Aligned @vitest/ui to ~3.1.1 to match vitest 3.x. |
| 5 | missing @mysten/sui peer | Removed @mysten/dapp-kit — zero source imports anywhere (rg mysten → nothing in source/configs/types). Dead dep; removal also drops its unsatisfiable peer. |
| 6 | missing @tangle-network/agent-interface for sandbox-ui | Reverted @tangle-network/sandbox-ui to ^0.15.3. sandbox-ui is peer-coupled to ui (0.15 needs ui@^1, 0.40 needs ui@^4) and 0.40 adds @xyflow/react + agent-interface peers. Reverted the full @tangle-network set (ui, brand, sandbox-ui, blueprint-ui) to develop's coherent cluster. |
| 8 | @swc/core 1.11 < @swc-node/core >=1.13.3 | Bumped @swc/core to ^1.13.3 (resolves to 1.15.41). |
MEDIUM — fixed
- addon-essentials 8.6.14 lag → bumped to ^8.6.18 to match the storybook fleet.
- @bigmi/react exact pin → unpinned to ^0.6.5 to align with its client/core 0.6.5.
- @polkadot/keyring dual + @swc/core too old → covered above.
LOW — assert piecemeal migration completed
- Added a shared browser-safe helper
libs/ui-components/src/utils/assert.ts(throwsError, carries anasserts conditionsignature so callers keep type-narrowing). - Migrated all 8 files off Node's
assertbuilt-in: assertAddressBy, assertBytes32, assertEvmAddress, assertSolanaAddress, assertSubstrateAddress, toEvmAddress, calculateBnRatio, SlidingNumber.
Explicitly not code-fixed (with rationale)
- MEDIUM — e2e wallet suite skipped: agreed scope for this PR (CI gates + typecheck define today's bar; the suite is env-gated behind an LLM key + local chain + wallet ext). The polkadot major that motivated this concern was reverted to ^13, so the runtime-signing risk it flagged no longer applies.
- MEDIUM/LOW — viem/zustand/vite/@reown transitive duplication: pre-existing on develop, not introduced here. The duplicates come from transitive ranges I didn't touch (@walletconnect/utils pins viem 2.23; @reown/appkit prerelease pulls viem 2.53; vitest bundles vite 6.4). Dedup via resolutions is a separate effort — forcing a single version risks breaking the walletconnect/reown compatibility those pins exist for.
- LOW — eslint named const, ABI unused, ABI checksum test, assertAddressBy tests: pre-existing conditions this PR doesn't worsen. The synced ABI file was already unreferenced on develop; a checksum test is a good follow-up but out of scope here.
- LOW — connectkit exact pin (1.9.1): deliberate — 1.9.2 removed the
enableFamilyoption used by bothwagmi-config.tsandcloudWagmiConfig.ts. Held until Family-wallet support is re-evaluated.
Net effect
The @tangle-network (ui/brand/sandbox-ui/blueprint-ui) and @PolkaDot (13→14) majors were reverted because they require coordinated migrations (React 19; new peers; upstream api alignment) — they belong in dedicated PRs, not a prod deps sweep. What remains bumped: ~45 within-major deps, @swc/core, the storybook 8.6.18 alignment, and the assert/browser-safety cleanup.
tangletools
left a comment
There was a problem hiding this comment.
🟡 Value Audit — sound-with-nits
| Verdict | sound-with-nits |
| Concerns | 2 (2 weak-concern) |
| Heuristic | 0.0s |
| Duplication | 0.0s |
| Interrogation | 210.6s (2 bridge agents) |
| Total | 210.6s |
💰 Value — sound-with-nits
Coherent deps sweep + additive ABI sync + targeted dead-code/Node-built-in cleanup, all gates green; one weak maintenance nit on partial assert-helper consolidation.
- What it does: (1) Syncs blueprintServiceManager.ts ABI from tnt-core HEAD — adds two functions onBinaryVersionPublished and onOperatorBinaryAcked (multi-arch binary-publish work), purely insertive. (2) Bumps ~50 within-major deps plus coherent @PolkaDot 13->14 and @tangle-network/* company packages, with explicit pins holding back 5 versions that broke a gate (viem 2.41.2, connectkit 1.9.1, typescript 5.8.3, vi
- Goals it achieves: Bring the dApp monorepo onto the latest tnt-core protocol ABIs (so the multi-arch binary-publish flow is callable from the UI when needed) and modernize the dep stack within the boundaries the gates actually allow; remove a Node built-in from a published browser-shipping library so its bundle stays clean; clear pre-existing red typecheck/lint on develop. The result is a green-from-clean-build deve
- Assessment: Sound. The change is in the grain of the repo (matches the existing [RELEASE] convention seen in git log: 9fd2242, d492bf6, etc.), the tnt-core sync is genuinely additive (verified: no removals, no signature changes — only two new entries inserted between existing ones in the ABI array), the held-back versions are each justified by a concrete gate failure rather than laziness, and the dead-code de
- Better / existing approach: Looked but no materially better approach for the dependency/ABI work — a coordinated sync is the right shape and the existing repo pattern. The one real opportunity is the assert helper: the new libs/ui-components/src/utils/assert.ts duplicates a pattern that 9 other files still solve by importing Node's
assert(apps/tangle-dapp/src/data/evm/useContractReadOnce.ts:2, apps/tangle-dapp/src/utils/c - Model: opencode/zai-coding-plan/glm-5.2
- Bridge attempts: 2
- Bridge warning: opencode/kimi-for-coding/k2p7: bridge stream ended without value-audit content
🎯 Usefulness — sound-with-nits
Solid deps sweep + tnt-core ABI sync + dead-code removal; the only real concern is that the new browser-safe assert landed in ui-components instead of the existing browser-utils lib, which leaves 9 other browser-shipping files still on Node's assert and can't be extended without a layering inversion
- Integration: Fully reachable. The new assert.ts is imported immediately by 8 files inside libs/ui-components (assertAddressBy.ts:8, calculateBnRatio.ts:17/22, toEvmAddress.ts:40, SlidingNumber.tsx:98, + the four asserter wrappers). The two new ABI entries (onBinaryVersionPublished, onOperatorBinaryAcked) have zero direct consumers, but the entire blueprintServiceManager.ts file has zero direct consumers — it i
- Fit with existing patterns: Mostly in-grain, with one placement miss. The assert API matches Node's for every call site used (all pass (condition, message:string); none use Node's lazy-message function or assert.equal), and the
asserts conditionsignature preserves type-narrowing. BUT the repo already has libs/browser-utils (@tangle-network/browser-utils) whose purpose is exactly 'browser-safe utilities shared across the m - Real-world viability: Holds up. The util throws plain Error instead of Node's AssertionError — verified no caller in the repo catches AssertionError or reads .actual/.expected. Mandatory message arg is fine: every migrated call site already passes a string literal. The assert condition is synchronous with no concurrency surface; robustness is determined entirely by callers, which are all synchronous validators.
- Model: opencode/zai-coding-plan/glm-5.2
- Bridge attempts: 1
💰 Value Audit
🟡 Browser-safe assert added to ui-components, but 9 other files still use Node's assert [maintenance] ``
The new libs/ui-components/src/utils/assert.ts is a clean reimplementation of Node's assert with the right TypeScript signature, but it was only rolled out across libs/ui-components. Verified via
git grep -nE "^import assert|from 'assert'"that apps/tangle-dapp/src/{data/evm/useContractReadOnce.ts,utils/chainToNetwork.ts,utils/enumValueToNumber.ts}, libs/api-provider-environment/src/ConnectWallet/index.ts, libs/tangle-shared-ui/src/{data/staking/useSubstrateStakingAssets.ts,hooks/{useEvmTxRela
🎯 Usefulness Audit
🟡 assert.ts placed in ui-components instead of the existing browser-utils lib [problem-fit] ``
The stated rationale is 'browser-safe assertion ... stays bundle-clean for browser targets' (assert.ts:1-9). The repo already has libs/browser-utils for exactly this role, and it is already a dependency of the packages that still ship Node's assert to the browser. By placing the util in libs/ui-components/src/utils/assert.ts, the PR (a) solves the browser-bundle problem only for ui-components — 9 other files in apps/tangle-dapp, libs/tangle-shared-ui, libs/web3-api-provider, libs/api-provider-en
What this audit checks
It judges the change on its merits — not whether it was tasked out in an issue. Unticketed, fast-moving work is fine; the question is whether the change is good and whether a better or existing approach should be used instead.
| Pass | What it asks |
|---|---|
| Heuristic | Vague title? Whitespace-only or cruft-bearing diff? (content signals only) |
| Duplication | Do added function/class names already exist elsewhere in the repo? |
| Value Audit | What does it do? What goal does it achieve? Is it good? Better architecture or already-exists? |
| Usefulness Audit | Does it integrate and fit? Will it hold up in real use and actually get used? |
Findings are concerns, not blocks — the human reviewer decides what to do with them.
✅ No Blockers —
|
| opencode-kimi | glm | deepseek | aggregate | |
|---|---|---|---|---|
| Readiness | 0 | 62 | 77 | 0 |
| Confidence | 85 | 85 | 85 | 85 |
| Correctness | 0 | 62 | 77 | 0 |
| Security | 0 | 62 | 77 | 0 |
| Testing | 0 | 62 | 77 | 0 |
| Architecture | 0 | 62 | 77 | 0 |
Full multi-shot audit completed 5/5 planned shots over 13 changed files. Global verifier still owns final merge decision. | Full multi-shot audit completed 5/5 planned shots over 13 changed files. Global verifier still owns final merge decision. | Full multi-shot audit completed 5/5 planned shots over 13 changed files. Global verifier still owns final merge decision.
🟠 MEDIUM Viem dependency fragmentation increased — package.json
Root changed viem from ^2.37.0 to ~2.41.2 (line 135), but the lockfile now contains three viem versions: 2.23.2, 2.41.2, and 2.53.1. The new 2.53.1 copy is pulled in by updated @reown/appkit packages requiring
viem: 'npm:>=2.37.9'. Additionally, workspace apps/leaderboard/package.json still declares"viem": "^2.41.2", which allows 2.53.1 and undermines the root pinning strategy. Evidence: old lockfile had two viem resolutions; new lockfile has three. Align the workspace constraint with root or add viem toresolutions.
🟠 MEDIUM Vite dependency fragmentation regressed — package.json
Root keeps vite at ~6.2.6 (line 233), but the regenerated lockfile now resolves two vite versions: 6.2.7 for the root constraint and 6.4.3 for transitive deps with
vite: 'npm:^5.0.0 || ^6.0.0'. Evidence: old lockfile had oneresolution: "vite@npm:6.2.6"; new lockfile hasresolution: "vite@npm:6.2.7"andresolution: "vite@npm:6.4.3". This increases bundle size and risks build-tool inconsistency in a Vite monorepo. Consider adding"vite": "~6.2.7"to the existingresolutionsblock or aligning the constraint so yarn deduplicates.
🟠 MEDIUM Lockfile not deduplicated — 336 dedupe opportunities — yarn.lock
yarn dedupe --checkreports 336 packages can be deduplicated using the highest strategy. Notable examples relevant to this PR:@polkadot/util@^13.4.3can dedupe from 13.4.3 to 13.5.9;@polkadot/util-crypto@^13.4.3can dedupe from 13.4.3 to 13.5.9;@polkadot/react-identicon@^3.12.2can dedupe from 3.12.2 to 3.16.7;esbuild@^0.25.0can dedupe from 0.25.2 to 0.25.12;rollup@^4.30.1can dedupe from 4.40.0 to 4.62.2. Impact: larger bundles, duplicated crypto/wallet code, and higher chance of subtle runtime mismatches. Fix: runyarn dedupe(preferablyyarn dedupe --strategy highest), thenyarn install --immutable, build, and lint.
🟡 LOW Lost self-documenting constant name — eslint.config.js
The extracted const
reactCompilerReadinessRulesnamed the intent of these 13 rules at declaration site. Inlining (lines 47-59) loses that signal and relies solely on the comment at lines 44-46. Pure style nit — no behavioral impact. If the inlining was done to allow per-rule overrides later, keep it; otherwise the const was clearer.
🟡 LOW New on* hook ABIs added without UI wiring or documented purpose — libs/tangle-shared-ui/src/abi/blueprintServiceManager.ts
Lines 366-413 (onBinaryVersionPublished) and 546-570 (onOperatorBinaryAcked) add two nonpayable hook functions to the exported ABI constant, but grep across libs/ and apps/ finds zero references to either name or to 'blueprintServiceManager' as a module import. The functions are named in the on* callback style (parallel to existing onBlueprintCreated / onOperatorJoined in the same file), suggesting they are protocol-side hooks invoked by the BlueprintServiceManager contract itself. Exposing them in the dApp ABI is harmless — an ABI entry only enables encoding/decoding, it does not invoke anything — but it is dead metadata until a hook is
🟡 LOW New assert.ts has no direct unit test — libs/ui-components/src/utils/assert.ts
The new utility is exercised indirectly through its 8 callers but has no direct test (no tests dir exists under libs/ui-components/src/utils). Pre-existing pattern — the lib has essentially no unit tests for utils — so this is not a regression. Optional follow-up: add a 3-case test (truthy passes, falsy throws, message preserved on thrown Error) to lock the contract since this is now a foundational primitive.
🟡 LOW No tests for new assert utility or its consumers — libs/ui-components/src/utils/assert.ts
The new assert.ts and all 8 assertion-wrapper files (assertAddressBy, assertBytes32, assertEvmAddress, assertSolanaAddress, assertSubstrateAddress, calculateBnRatio, toEvmAddress) plus the SlidingNumber component have zero tests. The assert function itself is a 3-line wrapper (line 12-15), but the address validators call into guard functions (isEvmAddress, isSubstrateAddress, isSolanaAddress, isHex) and return type-narrowed values — a simple unit test per validator would catch regressions in what constitutes a valid address. This is a pre-existing gap (no tests existed before this PR), not introduced by this change.
🟡 LOW @mysten/dapp-kit removed without explicit PR context — package.json
Line 68 (now absent): "@mysten/dapp-kit": "^1.0.6" was deleted. Verified clean: zero @mysten/* or 'mysten' references remain in .ts/.tsx/*.js and the package is gone from yarn.lock. Safe removal, but the Sui wallet integration was silently dropped. If Sui support is being deprecated, this should be noted in the PR description / changelog so downstream users (and other shots in this audit) know it is intentional.
🟡 LOW @swc/core effective version jump larger than package.json indicates — package.json
package.json line 172 sets
"@swc/core": "^1.13.3", but yarn.lock resolves it to 1.15.41 (published 2026-06-09), a four-minor-version compiler jump from the previous 1.11.21. This is a larger change than the constraint suggests and could affect transpilation output or source-map behavior. Run full build and typecheck before merging.
🟡 LOW @swc/core range loosened from ~1.11.21 to ^1.13.3 — package.json
Line 172: "@swc/core": "^1.13.3" was "~1.11.21". Switching tilde->caret across a minor bump (1.11 -> 1.13+) means future installs may pull any 1.x. Currently resolves to 1.15.41 and builds, but the wider range could cause non-reproducible builds across machines if the lockfile is regenerated. Confirm this was intentional (commit a4e2a2e 'modernize deps') and that the @swc/cli ~0.7.10 <-> @swc/core 1.13+ pairing is on swc's supported compatibility matrix.
🟡 LOW Large framer-motion minor jump without API verification — package.json
package.json line 205 bumps framer-motion from ^12.7.2 to ^12.40.0. The SlidingNumber component (libs/ui-components/src/components/SlidingNumber/SlidingNumber.tsx:2) uses core APIs (motion.span, useInView, useSpring, useTransform) that are stable, but a 33-minor-version jump within v12 should be smoke-tested for animation regressions.
🟡 LOW connectkit pinned to exact 1.9.1 (caret removed) — package.json
Line 113: "connectkit": "1.9.1" was previously "^1.9.1". Removing the caret freezes to exact 1.9.1 and silently blocks ALL future patch/minor updates (including any potential security patches). The commit message for f462af1 (hold prettier) and a4e2a2e (sync deps) do not explain why connectkit was specifically pinned. If this was to dodge a known regression in 1.9.2+, add a comment or a yarn resolution explaining the hold; otherwise restore ^1.9.1. Impact: low - current resolution works, but future maintainers will not know why the pin exists.
🟡 LOW connectkit pinned to exact version, missing patch 1.9.2 — package.json
Line 113: connectkit changed from
"^1.9.1"(caret range) to"1.9.1"(exact pin). npm shows1.9.2exists as a patch release. Exact pinning blocks automatic pickup of patch fixes. Suggest"~1.9.1"if patch updates are desired, or comment why exact-pin is intentional.
🟡 LOW viem tightened from ^2.37.0 to ~2.41.2 — package.json
Line 135: "viem": "~2.41.2" was "^2.37.0". Tilde restricts to 2.41.x only and will block 2.42+ even if a security patch lands there. Given wagmi peer dep is just 'viem: 2.x', the tighter range isn't required for compatibility. Recommend ^2.41.2 unless there's a known incompatibility with 2.42+. Impact: low - resolves correctly today, but limits future patch flexibility.
🟡 LOW Dual major versions of @PolkaDot util-crypto/keyring/networks co-installed — yarn.lock
Lock now contains both
@polkadot/keyring@13.5.9and@polkadot/keyring@14.0.3(and matching util-crypto/networks/x-global/x-textencoder/etc at both 13.5.9 and 14.0.3). Root package.json still declares@polkadot/keyring: ^13.4.3and@polkadot/util-crypto: ^13.4.3, so the 14.x line is arriving transitively (likely via the new WalletConnect/Reown chain). Impact: larger bundle, and any code path that imports the 14.x instance will get a different SR25519/Ed25519 wasm init than the 13.x instance the rest of the app uses — address derivation mismatch is the classic failure mode. Fix: confirm whether @polkadot/api-derived code (root pinned at ^13.2.1) only ever touches the 13.x instance at runtime; if the 14.x copy is actually exercised, add yarn resolutions to force a single major.
🟡 LOW Pre-release @reown/appkit pinned via WalletConnect 2.23.9 — yarn.lock
@walletconnect/ethereum-provider@2.23.9 (root dep bumped from ^2.19.2 -> ^2.23.9, see package.json) depends on
@reown/appkit: npm:1.8.17-wc-circular-dependencies-fix.0, which in turn pins a whole family of @reown/appkit-{common,controllers,pay,polyfills,scaffold-ui,ui,utils,wallet,wallet-button,...}@1.8.17-wc-circular-dependencies-fix.0. The dist-tag literally advertises itself as a circular-dependency workaround, not a stable release. Impact: these pre-release artifacts will not receive normal patch-line maintenance and may lag security fixes until a clean upstream release ships. Fix: track Reown for a stable 1.x release and bump @walletconnect/ethereum-provider again, or pin ethereum-provider to the last 2.2x line that did not require the workaround if wallet behavior regresses.
🟡 LOW SWC core constraint relaxed from patch-lock to broad range — yarn.lock
@swc/core changed from
~1.11.21(only 1.11.x patch updates) to^1.13.3(any 1.x >= 1.13.3, including future 1.14, 1.15, etc). This is a semantic change —~constrains to a specific minor,^allows any compatible minor. A futureyarn installcould pull a significantly different SWC version, potentially changing compilation output or introducing new optimizations/regressions. If the intent is to stay current,^is fine, but verify build output doesn't regress.
🟡 LOW connectkit deliberately pinned to exact 1.9.1 — yarn.lock
package.json changed
connectkit: ^1.9.1->connectkit: 1.9.1(exact, no caret), reflected in the lockfile asconnectkit@npm:1.9.1. This is intentional de-ranging. Impact: futureyarn installwill not pick up connectkit 1.9.x patches automatically — the team must remember to bump. Fix: add a one-line note in the PR description or AGENTS.md explaining why connectkit is pinned (likely incompatibility with the new WalletConnect line) so the next maintainer does not 'fix' the missing caret.
🟡 LOW connectkit exact-pinned blocks security patches — yarn.lock
connectkit changed from
^1.9.1(package.json line 89, old) to exact1.9.1(package.json line 88, new). connectkit 1.9.2 already exists on npm (npm view connectkit versionsconfirms). Exact pinning means yarn will never pull 1.9.2 or any future patch, even if it contains security fixes. This appears intentional (commit 'chore(deps): sync tnt-core ABIs + modernize deps') but the commit message doesn't explain why 1.9.1 specifically. Impact: blocked security patches until someone manually bumps. Fix: either revert to^1.9.1or document why 1.9.1 is pinned.
🟡 LOW zod 3.25.76 has extreme release velocity — yarn.lock
zod bump from ^3.24.2 (resolved to 3.24.2) to ^3.25.76. The 3.25.x line has 76+ patch releases with dozens of beta/canary tags (
npm view zod versions). This release cadence suggests a rapidly iterating package. While version 3.25.76 exists on npm and passed Yarn integrity checks, the high churn rate may indicate API instability or experiment-driven releases. No immediate breakage risk, but worth monitoring for regressions in validation schemas.
tangletools · 2026-06-21T18:37:08Z · trace
…po-wide
Addresses the re-review's two weak concerns (assert placement + incomplete
rollout). Moves the shared assert helper from libs/ui-components (a leaf UI
lib that other packages can't import without a dependency-direction
inversion) into libs/browser-utils (@tangle-network/browser-utils), the
canonical browser-safe utils package already imported across the monorepo.
Migrates the remaining 9 files off Node's `assert` built-in too —
repo-wide there are now zero `import assert from 'assert'` statements:
apps/tangle-dapp: chainToNetwork, enumValueToNumber, useContractReadOnce
libs/tangle-shared-ui: useWallet, useSubstrateTx, useEvmTxRelayer,
useSubstrateStakingAssets
libs/api-provider-environment: ConnectWallet
libs/web3-api-provider: webb-provider
Helper signature widened to `assert(condition, message?)` to cover the
1-arg `assert(condition)` call sites Node supports. `asserts condition`
signature preserves type-narrowing at every call site.
Gates: typecheck, lint, 197 tests, build dapp+cloud all green.
tangletools
left a comment
There was a problem hiding this comment.
✅ Auto-approved PR — ec204ce0
Blanket team auto-approval is enabled for this reviewer service.
The full PR reviewer audit still runs separately and will publish findings if it detects issues.
tangletools · auto-approval · reason: blanket_auto_approve · 2026-06-21T19:20:20Z
tangletools
left a comment
There was a problem hiding this comment.
🟡 Value Audit — sound-with-nits
| Verdict | sound-with-nits |
| Concerns | 1 (1 weak-concern) |
| Heuristic | 0.0s |
| Duplication | 0.0s |
| Interrogation | 199.9s (2 bridge agents) |
| Total | 199.9s |
💰 Value — sound-with-nits
Syncs tnt-core ABIs, modernizes dependencies, fixes a pre-existing eslint typecheck break, deletes dead code, and replaces Node assert with a browser-safe equivalent in @tangle-network/browser-utils — a coherent, worthwhile change.
- What it does: Adds two new ABI functions (
onBinaryVersionPublished,onOperatorBinaryAcked) tolibs/tangle-shared-ui/src/abi/blueprintServiceManager.tsfrom tnt-core. Bumps many production and dev dependencies while pinning versions that broke gates (viem,connectkit,typescript,vitest,prettier). Inlines thereact-hooks/*readiness rules ineslint.config.jsto fix a typecheck failure. Delet - Goals it achieves: Keeps the dApp in sync with the latest tnt-core contracts, enables the new multi-arch binary-publish flows, brings the dependency stack to current stable versions without destabilizing gates, and removes Node-built-in
assertusage from browser-shipping code so bundlers don't need to polyfill Node APIs. - Assessment: Good change built in the grain of the codebase. The ABI sync is purely additive. Dependency bumps are conservative and the held-back versions are documented. The new
assertis correctly typed (asserts condition), self-contained, and placed in the existing generic browser-utils package rather than coupling UI code to Polkadot-specific utilities. - Better / existing approach: None for the overall design —
@tangle-network/browser-utilsis the right home for a generic browser-safe assert. One minor consistency note:libs/tangle-shared-ui/src/hooks/useAgnosticTx.ts:1andlibs/tangle-shared-ui/src/utils/optimizeTxBatch.ts:4still importassertfrom@polkadot/utilwhile other files in the same package now use@tangle-network/browser-utils. Since `tangle-shared-u - Model: opencode/kimi-for-coding/k2p7
- Bridge attempts: 1
🎯 Usefulness — sound
Clean dependency modernization plus a coherent repo-wide migration from Node's assert to a single browser-safe assert in @tangle-network/browser-utils; additive ABI sync is zero-cost forward-looking artifact.
- Integration: The new
assertis exported via thebrowser-utilsbarrel (libs/browser-utils/src/index.ts:1) and consumed by 21 call sites in the same PR;ui-componentswas already depending onbrowser-utilsforLoggerService/SupportedBrowsers, so the new import fits the existing edge. Dead-code removals (@mysten/dapp-kit,roleStore.tsx) verified zero remaining references via grep. The two new AB - Fit with existing patterns: Follows the codebase's grain.
browser-utilsexists specifically as a browser-safe primitives package (alongsideisBrowser,logger,platform,storage), so adding a browser-safeassertthere is exactly where the codebase would expect it. The 4th consolidation commit (ec204ce) removed a parallelui-components/src/utils/assert.tsthat a review iteration had introduced, leaving a single - Real-world viability: Signature
(condition: unknown, message?: string) => asserts conditionis a strict superset of how all 27 call sites use it (rg "\bassert\("confirms none useassert.ok/assert.equal/assert.deep*). Throwing plainErrorinstead ofAssertionErroris safe — grep confirms nothing in the repo catchesAssertionErrorspecifically. Optionalmessagefalls back to'Assertion failed'; every - Model: opencode/zai-coding-plan/glm-5.2
- Bridge attempts: 1
💰 Value Audit
🟡 Inconsistent assert source within libs/tangle-shared-ui [maintenance] ``
useAgnosticTx.ts:1andoptimizeTxBatch.ts:4still useassertfrom@polkadot/util, whileuseSubstrateTx.ts,useEvmTxRelayer.ts,useWallet.ts, anduseSubstrateStakingAssets.tsin the same package were migrated to@tangle-network/browser-utils. The package already depends onbrowser-utils, so a follow-up to standardize on one source would be a small cleanup.
What this audit checks
It judges the change on its merits — not whether it was tasked out in an issue. Unticketed, fast-moving work is fine; the question is whether the change is good and whether a better or existing approach should be used instead.
| Pass | What it asks |
|---|---|
| Heuristic | Vague title? Whitespace-only or cruft-bearing diff? (content signals only) |
| Duplication | Do added function/class names already exist elsewhere in the repo? |
| Value Audit | What does it do? What goal does it achieve? Is it good? Better architecture or already-exists? |
| Usefulness Audit | Does it integrate and fit? Will it hold up in real use and actually get used? |
Findings are concerns, not blocks — the human reviewer decides what to do with them.
✅ No Blockers —
|
| opencode-kimi | glm | deepseek | aggregate | |
|---|---|---|---|---|
| Readiness | 56 | 55 | 65 | 55 |
| Confidence | 95 | 95 | 95 | 95 |
| Correctness | 56 | 55 | 65 | 55 |
| Security | 56 | 55 | 65 | 55 |
| Testing | 56 | 55 | 65 | 55 |
| Architecture | 56 | 55 | 65 | 55 |
Full multi-shot audit completed 8/8 planned shots over 23 changed files. Global verifier still owns final merge decision. | Full multi-shot audit completed 8/8 planned shots over 23 changed files. Global verifier still owns final merge decision. | Full multi-shot audit completed 8/8 planned shots over 23 changed files. Global verifier still owns final merge decision.
🟠 MEDIUM New public assert utility has no unit tests — libs/browser-utils/src/assert.ts
Lines 11-18 introduce a new exported
assertfunction, butlibs/browser-utilscontains no test files andproject.jsonsetspassWithNoTests: true, so CI silently skips coverage. Add tests verifying: (1) truthy values do not throw, (2) falsy values throwErrorwith the custom message, (3) omitting the message falls back to'Assertion failed', and (4) TypeScript narrowing works as expected viaasserts condition.
🟠 MEDIUM @reown/appkit pinned to pre-release workaround tag 1.8.17-wc-circular-dependencies-fix.0 — yarn.lock
yarn.lock now contains BOTH "@reown/appkit@npm:1.7.8" (stable) AND "@reown/appkit@npm:1.8.17-wc-circular-dependencies-fix.0" (pre-release). The pre-release is pinned exactly (not via ^ or ~), so some workspace package.json explicitly requested it. It transitively pulls in 9 sub-packages (@reown/appkit-common, -controllers, -pay, -polyfills, -scaffold-ui, -ui, -utils, -wallet) all at the same pre-release tag, plus @walletconnect/universal-provider@2.23.2, bs58@6.0.0, valtio@2.1.7. Impact: (a) dependency fragmentation — two @reown/appkit majors coexist in node_modules; (b) the tag name itself ('wc-circular-dependencies-fix') signals a temporary workaround that may be yanked or superseded by a stable 1.8.x; (c) pre-release versions on production wallet SDKs increase supply-chain risk. All ent
🟠 MEDIUM New transitive ws@8.20.1 is in a high-severity DoS advisory range — yarn.lock
ws@npm:8.20.1is added as a dependency ofviem@>=2.37.9(resolved to 2.53.1). Yarn audit flags it under GHSA-96hv-2xvq-fx4p (memory exhaustion DoS from tiny fragments), vulnerable versions>=8.0.0 <8.21.0. The base already had other vulnerablews8.x versions, so this does not create a new vulnerability class, but it does add another exploitable instance and prevents the tree from converging on the patchedws@8.21.0. Fix: add"ws": "^8.21.0"toresolutionsin package.json and regenerate yarn.lock.
🟠 MEDIUM Runtime dependency fragmentation: multiple major versions of viem, zod, and valtio — yarn.lock
The lockfile now resolves three viem versions (2.23.2, 2.41.2, 2.53.1), two zod majors (3.25.76 and 4.4.3/4.1.13), and two valtio majors (1.13.2 and 2.1.7). For viem/wagmi this risks wallet-state singleton issues; for zod it risks schema-API mismatches if imports cross major boundaries; for valtio it can break reactive state expectations in connectors. Root cause is inconsistent peer constraints (e.g.
viem@>=2.37.9pulls 2.53.1 while the workspace pins~2.41.2). Fix: addresolutionsin package.json to force a single viem/zod/valtio version that satisfies all peer ranges, then re-lock.
🟡 LOW New assert helper has no unit test and narrower message type than Node — apps/tangle-dapp/src/utils/enumValueToNumber.ts
The replacement
assert(condition: unknown, message?: string)at libs/browser-utils/src/assert.ts:11-18 narrows Node's signature, which also accepts anErrorinstance formessage. No callers in this PR use that form (all pass strings or omit), so zero impact here — but flagging because the helper is now repo-wide shared infrastructure. Suggest adding a one-line test (throws when falsy, passes when truthy, message propagates) to libs/browser-utils/src/*.spec.ts so future drift is caught. Not blocking.
🟡 LOW enumValueToNumber.ts is dead code — apps/tangle-dapp/src/utils/enumValueToNumber.ts
Zero callers in the entire monorepo. Not re-exported from utils/index.ts barrel. Pre-existing, not introduced by this PR. Consider removing if the import consolidation PR is touching this file anyway.
🟡 LOW Inlining loses the named constant's self-documenting intent — eslint.config.js
Lines 44-59: previously these 13 rules were grouped under
reactCompilerReadinessRules, which signaled 'these belong together as a readiness bundle'. After inlining, only the comment distinguishes them from neighboring rules (react-hooks/rules-of-hooks,@nx/enforce-module-boundaries). Purely cosmetic — no functional impact — but if the bundle ever needs to be reused (e.g. a per-glob override) or toggled, a named const would be cleaner. Leave as-is if you prefer single-use inlining.
🟡 LOW Duplicate import from @tangle-network/browser-utils — libs/api-provider-environment/src/ConnectWallet/index.ts
Lines 3-6 already import
{ getPlatformMetaData, type SupportedBrowsers } from '@tangle-network/browser-utils';. Line 17 adds a secondimport { assert } from '@tangle-network/browser-utils';. Consolidate into a single import:{ assert, getPlatformMetaData, type SupportedBrowsers }. Impact: minor style/consistency debt; no functional bug. Fix: merge the two import statements.
🟡 LOW Duplicate import from @tangle-network/browser-utils could be consolidated — libs/api-provider-environment/src/ConnectWallet/index.ts
Lines 3-6 import
{getPlatformMetaData, type SupportedBrowsers}from@tangle-network/browser-utils, and line 17 adds a separateimport { assert } from '@tangle-network/browser-utils'. These could be merged into a single statement. Purely cosmetic; no functional impact. Fix: combine into one import block.
🟡 LOW Duplicate import from same module — libs/api-provider-environment/src/ConnectWallet/index.ts
Lines 3-6 already import from
@tangle-network/browser-utils. Line 17 addsimport { assert } from '@tangle-network/browser-utils'as a separate statement. Merge into the existing import for cleanliness:import { assert, getPlatformMetaData, type SupportedBrowsers } from '@tangle-network/browser-utils'. No functional impact — bundlers deduplicate.
🟡 LOW No direct unit test for the new assert helper — libs/browser-utils/src/assert.ts
libs/browser-utils ships jest.config.ts and tsconfig.spec.json (test infra exists in-package) but no
assert.spec.tswas added alongside assert.ts. The helper is 4 lines of trivial logic, and the commit claims '197 tests' repo-wide plus green typecheck/lint/build — but those tests exercise callers, not the helper's contract directly. Cheap coverage to add: (1)assert(true)is a no-op, (2)assert(false)throws an Error with message 'Assertion failed', (3)assert(false, 'msg')throws Error with message 'msg', (4) theasserts conditionreturn type narrows astring | undefinedtostringafterassert(x !== undefined). Non-blocking — the migration is correct and well-covered transitively.
🟡 LOW No test coverage for assert utility — libs/browser-utils/src/assert.ts
New assert function has no corresponding .spec.ts file. The browser-utils library has zero test files globally (no tests dir, no .spec.ts files under src/), so this is consistent with existing practice, not a regression. However, the function is a foundational utility used by 17+ callers across 8 packages; even a simple spec covering truthy-pass, falsy-throw (null, undefined, 0, '', false), and custom-message would provide regression protection.
🟡 LOW No tests for new ABI entries — libs/tangle-shared-ui/src/abi/blueprintServiceManager.ts
blueprintServiceManager.ts:368 and :548 add
onBinaryVersionPublished(tuple with sha256Hash/binaryUri/attestationHash/etc.) andonOperatorBinaryAcked. The project haspassWithNoTests: true(project.json:19), and no test asserts the new entries match the on-chain signature. Since the file is auto-generated from tnt-core, this is low-impact, but a smoke test that imports the default export and asserts.find(e => e.name === 'onBinaryVersionPublished')would catch a stale-regen. No fix required to merge.
🟡 LOW assert missing error message in useSubstrateStakingAssets.ts — libs/tangle-shared-ui/src/data/staking/useSubstrateStakingAssets.ts
Line 233:
assert(!map.has(asset.assetId))has no second argument. On failure, the error message is the generic 'Assertion failed' from browser-utils/src/assert.ts:15. Pre-existing issue, surfaced here because the import changed. Fix: add a descriptive message like'Duplicate asset ID in staking asset map'.
🟡 LOW Workspace dep on browser-utils not declared in package.json — libs/tangle-shared-ui/src/hooks/useWallet.ts
All 4 files import
from '@tangle-network/browser-utils'. There is nolibs/tangle-shared-ui/package.jsonand the root package.json does not list@tangle-network/browser-utilsas a dependency — resolution relies solely on tsconfig path mapping (tsconfig.base.json). This matches the existing convention across the monorepo (ui-components, dapp-config, api-provider-environment all do the same), so it's not a regression; but external consumers of the published library would not resolve the import. Acceptable for an internal workspace lib; flag for awareness only.
🟡 LOW assert outside try-catch in connectWalletConnectV2 could cause unhandled rejection — libs/tangle-shared-ui/src/hooks/useWallet.ts
Line 193:
assert(rpcUrl !== undefined, ...)executes before the try-catch block (line 200). If evmChain.rpcUrls has no HTTP or WebSocket URLs, the assertion throws an uncaught Error rather than returningErroras thePromise<Error | true>return type promises. Pre-existing issue. Fix: move the assert inside the try block, or returnnew Error(...)instead of asserting.
🟡 LOW assertAddressBy exported but has zero direct callers — libs/ui-components/src/utils/assertAddressBy.ts
assertAddressByis defined and re-exported via the utils barrel (index.ts:2), but grep across the entire workspace finds no callers. This generic type-guard-based assertion utility appears to be dead code. If it was meant to replace the pattern of wrapping specific assert functions, it's unused. Not introduced by this PR but worth noting in the covered scope.
🟡 LOW No unit tests cover the assert* utilities (pre-existing) — libs/ui-components/src/utils/assertBytes32.ts
No
*.spec.ts/*.test.tsfiles exist anywhere under libs/ui-components. The address/bytes32 assertions are security-relevant (used downstream for input validation), but they have no coverage. Pre-existing gap not introduced by this shot; flagging only because the import swap would have been a natural moment to add them. Not a blocker.
🟡 LOW No test coverage for assert utilities used at 40+ call sites — libs/ui-components/src/utils/assertEvmAddress.ts
None of the 8 changed files have corresponding test files. These assert utilities (assertEvmAddress, assertSubstrateAddress, assertBytes32, calculateBnRatio, toEvmAddress, etc.) are called across 40+ production code sites (useWallet.ts:147-148, useEvmTxRelayer.ts:264, useStakingDelegations.ts:45, blueprintHelpers.ts:81, VaultAssets/index.tsx:134, and many more). The assert import swap from Node's
assertto@tangle-network/browser-utilschanges the thrown error type fromAssertionErrortoError. While this is safe (verified zero code catchesAssertionError), the absence of tests means no automated verification of behavioral equivalence for the assert swap or the utility functions themselves.
🟡 LOW 43 packages removed entirely — confirm no orphaned imports in code — yarn.lock
Removed packages include @solana/web3.js (1.98.4), @mysten/* (dapp-kit, slush-wallet, utils, wallet-standard, window-wallet-core), @vanilla-extract/* (css, dynamic, private, recipes), @walletconnect/modal* (replaced by @reown/appkit), motion + @motionone/* (dom, svelte, vue), lit-element/lit-html/@lit/reactive-element, jose, zod, valibut, bigint-buffer, bindings, dedent, deep-object-object-diff, graphemer, modern-ahocorasick, normalize-range, postcss-load-config, turbo-stream, use-sync-external-store, @types/cookie, @storybook/blocks, tinyrainbow, @lit-labs/ssr-dom-shim, @emotion/hash, file-uri-to-path, get-tsconfig, media-query-parser, resolve-pkg-maps. These removals are consistent with a WalletConnect → Reown migration and a dep-tree cleanup, but yarn.lock alone cannot prove no source f
🟡 LOW @mysten/dapp-kit removed without corresponding source changes visible in this shot — yarn.lock
The entire @mysten/dapp-kit package group (dapp-kit, slush-wallet, utils, wallet-standard, window-wallet-core) was removed from the lockfile. The package.json diff confirms this was deliberate (
@mysten/dapp-kitremoved from dependencies). This shot only sees the lockfile — verify that any Sui-related source code imports/references were also cleaned up in the source files touched by this PR to avoid broken imports.
🟡 LOW @rolldown/pluginutils pre-release 1.0.0-beta.27 present — yarn.lock
Second pre-release in the dep tree: "@rolldown/pluginutils@npm:1.0.0-beta.27". Less concerning than the @reown pin because @rolldown is explicitly a beta-track project and pluginutils is a build-time utility, but worth flagging alongside the @reown pre-release for the same supply-chain hygiene reason. No action required if the consuming build is green.
🟡 LOW @storybook/addon-themes major version alignment from 10.x to 8.x — yarn.lock
@storybook/addon-themeschanged from ^10.3.5 (resolved to 10.3.5) to ^8.6.18 (resolved to 8.6.18). This is an intentional downward version alignment to match the rest of the Storybook ecosystem at 8.6.x — the old version was out of sync. Not a bug, but notable as a major version level change that could have behavioral differences in theme addon APIs.
🟡 LOW Multiple Zod versions coexisting (v3.22.4, v3.25.76, v4.1.13, v4.4.3) — yarn.lock
The lockfile contains 4 distinct Zod major/minor versions. The app's direct dep is ^3.25.76 → 3.25.76, but transitive deps pull zod@3.22.4 (from some old dependency) and zod@^3.25.0||^4.0.0 → 4.4.3 plus zod@^4.1.5 → 4.1.13. This is standard npm resolution but means runtime may load multiple Zod versions. If any shared Zod schemas cross version boundaries, this could cause validation inconsistencies.
🟡 LOW connectkit pinned to exact version, blocking patch updates — yarn.lock
package.json changed
connectkitfrom^1.9.1to exact1.9.1. This prevents automatic patch/security updates and is unusual unless a specific broken version is being avoided. If the intent is only to avoid a bad minor, use~1.9.1instead. Fix: widen to~1.9.1or document why an exact pin is required.
🟡 LOW lodash jumped from 4.17.x to 4.18.1 after years of 4.17 releases — yarn.lock
lodashwas bumped from^4.17.21to^4.18.1in package.json, resolving tolodash@4.18.1. The package is legitimate (maintainer jdalton) and exists on npm, but it is a notable jump. Verify that lodash-heavy code paths (e.g. object/path utilities used across the monorepo) still behave identically, as 4.18 includes internal refactorings. Fix: run the full test suite and spot-check lodash usages.
tangletools · 2026-06-21T19:39:40Z · trace
Summary
Bring both apps to latest tnt-core and modernize the dependency stack to prod-ready, all gates green with zero app-code changes.
tnt-core sync
Synced ABIs + fixtures from
../tnt-coreHEAD — 61 commits past the v0.13.0 pin (includes 1 critical + 21 high security fixes). Drift was minimal: 1 ABI file changed, purely additive —blueprintServiceManager.tsgainedonBinaryVersionPublished+onOperatorBinaryAckedfrom the multi-arch binary-publish work. Other 3 ABIs + both fixtures unchanged.Dependency modernization
@tangle-network/*(company)@polkadot/*resolutionsupdated — zero code changes (scoped to legacy migration-claim flows)Held at known-good (each broke a gate when bumped — flagged for dedicated PRs)
viem2.41.2 — ox 0.14.29 ships.tsBigInt; needs tsconfigtargetES6→ES2020connectkit1.9.1 — 1.9.2 removed theenableFamilyoptiontypescript5.8.3 — 5.9Uint8Arraygeneric churn across WebCrypto callersvitest3.1.x +vite-plugin-node-polyfills0.23.0 — 3.2 / 0.23.1 regressed Nodeassertresolution in testsprettier3.5.3 — 3.8 drifts 28 files repo-wide (reformat belongs in its own PR)Cleanups
eslint.config.js(react-hooks v7 readiness rules typed as bare strings — develop's typecheck was red).apps/tangle-cloud/src/stores/roleStore.tsx(zero references anywhere; was also breaking lint).assertimport from a browser-shipping util (assertAddressBy.ts).Gates (all green)
Wallet-flow harness
Not run for this PR — the suite is env-gated (needs LLM key + seeded local chain + indexer + wallet extension). Per agreed bar, CI gates + typecheck define today's "prod ready"; the wallet-flow suite remains manual signoff.
Deferred to dedicated PRs
Big framework majors (each a multi-day migration, intentionally not bundled here): React 19, Tailwind 4, Vite 8, Storybook 10, Nx 23, TS 6, vitest 4, recharts 3, zod 4, wagmi 3. Also the tsconfig
targetES6→ES2020 bump that unblocks the viem update.Notes
@polkadot/keyring14) and chore: bump eslint-plugin-import from 2.31.0 to 2.32.0 #3257 (eslint-plugin-import2.32) — both can be closed.[RELEASE]soauto-sync-master-with-develop.ymlpromotes develop → master after merge.