fix(ui): distinguish a failed related-Multisig-calls fetch from an empty result#6501
fix(ui): distinguish a failed related-Multisig-calls fetch from an empty result#6501davion-knight wants to merge 1 commit into
Conversation
…pty result The "Related Multisig calls" section computed relatedCalls from a useQuery with no isError branch. A genuine failure leaves data undefined, so relatedCalls became [] and the section rendered "No other extrinsics reference this call_hash yet." -- asserting something the app doesn't know, and identical to a real empty result. Every other secondary query on the sibling accounts.$ss58.tsx page checks isError and renders TableState variant="error" with retry. Adds that branch. The order is the fix: isLoading -> isError -> rows -> empty, so the empty copy is only reachable when the fetch actually succeeded with zero rows. Verified by forcing the failure (aborting only the related-calls lookup, the one request carrying call_hash=, leaving the extrinsic detail healthy): before, the page claims there are no related calls; after, it shows the error state with a retry. Both still render the section. Closes JSONbored#6426
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #6501 +/- ##
=======================================
Coverage 97.85% 97.85%
=======================================
Files 174 174
Lines 22196 22196
Branches 8798 8798
=======================================
Hits 21721 21721
Misses 81 81
Partials 394 394 🚀 New features to boost your workflow:
|
|
Warning ⏸️ LoopOver review result - manual review recommendedReview updated: 2026-07-17 12:40:51 UTC
Review summary Nits — 4 non-blocking
Decision drivers
Context & advisory signals — never blocks the verdict
Linked issue satisfactionAddressed Review context
Contributor next steps
Signal definitions
🧪 Chat with LoopOverAsk LoopOver a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://loopover.ai/docs/loopover-commands 🧪 Experimental — new and may change. Visual preview
Click any thumbnail to open the full-size screenshot. Before = production · After = this PR's preview deploy. 🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by LoopOver, a quiet PR intelligence layer for OSS maintainers.
|
|
LoopOver closed this because @davion-knight has 3 open pull requests, above this repository's configured limit of 2. Close or merge an existing one to open a new one. This is an automated maintenance action. |

What
The "Related Multisig calls" section computed
relatedCallsfrom auseQuerywith noisErrorbranch. A genuine fetch failure leavesdataundefined, sorelatedCallsbecomes[]and the section rendered:— asserting a fact the app doesn't actually know. Every other secondary query on the sibling
accounts.$ss58.tsxpage checksisErrorand rendersTableState variant="error"with retry; this one now does too.The branch order is the fix:
isLoading → isError → rows → empty, so the empty copy is only reachable when the fetch genuinely succeeded with zero rows (the issue's second requirement).Proof — the error state, forced
Screenshots can't show this fix: on a healthy page the fetch succeeds, so before and after are identical. So I forced it, aborting only the related-calls lookup (it's the only request carrying
call_hash=; the extrinsic detail itself stays healthy — exactly the scenario the issue describes):Both still render the section, and both aborted the same 4 requests.
Screenshots
/extrinsics/0x25a23bcd…at#multisig-chain, showing the section in its successful empty state — identical before/after, since the new branch only renders on failure.One note on picking that extrinsic: the section only renders when
multisigCallHash()resolves, andas_multicalls here carry a nested decodedcallwith nocall_hash— so they render no section at all.approve_as_multicarriescall_hashdirectly, which is why this hash was used.before
after
before
after
before
after
before
after
before
after
before
after
Testing
extrinsics-multisig-error.test.ts(5 tests) — source assertions (this section lives in a route needing a router and live data; the suite is node-environment, and the repo tests this way in ui-kit'slist-shell.test.ts):isErrorbranch exists for the related-calls query;variant="error"witherror={relatedQuery.error}and arefetchretry, per theaccounts.$ss58.tsxpattern;isErroris checked before the empty copy — asserted by index, since a branch that exists but sits after the empty case would still let a failure fall through;isLoadingstays ahead of both, so a pending fetch isn't reported as an error;Verified meaningful: 4 of the 5 fail against the upstream file (the 5th passes both ways by design — it asserts the empty copy survives).
apps/ui: 141 files / 1065 tests pass,tscclean,eslint0 errors,format:checkclean. Diff is 2 files, both underapps/ui/src.Closes #6426