fix(fleet-ui): pair-dialog v-else compiler error + TTL docstring correction #27
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "fix/pair-dialog-and-ttl-doc"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Two post-merge corrections to the pairing UI (#25) and TTL work (#23), both validated against a live regtest stack (FakeWallet + lnbits
dev@b5fba561+ real nsecbunkerddev@cb8dd0c).1. Fleet UI — Pair dialog Vue compiler error 30 (
fix(fleet-ui))The Pair dialog (#25) had two interleaved
v-if/v-elsesibling pairs —q-card-section+q-card-actionsfor each of the two steps:Vue matches
v-elseto the immediately preceding sibling, so the secondv-else(actions) trailed av-else(section) — illegal. The compiler threw error 30 (X_MISSING_END_TAG/ "v-else has no adjacent v-if"), aSyntaxErrorthat broke the entire Vue mount — the whole extension page failed to render, not just the dialog. (A plain tag-balance check passes; this is a directive-adjacency rule, caught with@vue/compiler-dom.)Fix: wrap each step's
section+actionsin a single<template v-if>/<template v-else>so there's exactly one adjacent pair.Smoke-tested live: page renders; full Pair round-trip (mint key →
spirekeeper-spirepolicy with kinds21000/21001-3/22242/30078+nip44_*, nonip04→ token → seed URL + QR;machine_npubreassigned to the bunker-minted identity) and Revoke (never-bound branch,paired_atcleared) both confirmed.2.
pairing.py—duration_hoursTTL docstring (docs(pairing))The docstring claimed the bunker "rejects the token once it lapses, forcing a re-pair." That's only true for an un-redeemed token. nsecbunkerd reads
Token.expiresAtsolely invalidateTokenat connect/redeem time; the sign-time ACL never checks it (materialisedSigningConditions carry no expiry; the policy join filtersrevokedAtonly). Soduration_hoursbounds only the first-connect window —revoke_key_useris the real post-bind cutoff (same ACL-ordering class as the revoke finding #22).Corrected to say so, pointing at aiolabs/nsecbunkerd#24 (post-bind TTL enforcement gap).
No code-behavior change in (2); (1) is template-only. 211 tests already green on
main; neither touches Python logic or tests.🤖 Generated with Claude Code
The Pair dialog had two interleaved v-if/v-else sibling pairs (q-card-section + q-card-actions per step). Vue requires v-else to immediately follow its v-if sibling, so the second v-else (actions) trailed a v-else (section) — illegal, throwing compiler error 30 ("v-else has no adjacent v-if") and breaking the entire Vue mount. Wrap each step's section+actions in one <template v-if> / <template v-else> so there's exactly one adjacent pair. Verified with @vue/compiler-dom and a live pair/revoke round-trip against regtest. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>