fix(pairing): default bunker_relay to the spire's public event relay, not localhost #35
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "fix/pair-bunker-relay-default"
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?
The bug (flagged by bitspire on the demo)
A seed minted via the Pair UI bakes an unreachable bunker relay into
bunker_url:The Pair form has no
bunker_relayfield, sopair_spirefalls back to its defaultsettings.lnbits_nsec_bunker_url— which on a deployed instance is the internal relay lnbits uses to reach the co-located bunker (ws://127.0.0.1). The remote Sintra can't reach localhost →connectNewSeedhangs →BunkerTimeoutError"Signer Unreachable." This is the localhost-relay /pair gotcha the coord thread called out long ago.Fix
Default
bunker_relayto the spire's own public event relay (relays[0]): the bunker lives on the same operator nostrrelay the spire publishes its events to, so that URL is machine-reachable. An explicitbunker_relaystill overrides (split-relay deploys). An empty override now falls back to the same default instead of raising.Regression test: with no (or empty)
bunker_relay,bunker_urlembedsrelays[0]and contains no127.0.0.1.Pairing tests 15/15; full suite 212 passed (only the 2 pre-existing
test_pair_endpointfailures from #29 drift, #34);ruffclean.Not settled — follow-up
relays[0]is a pragmatic default. Whether the seed should carry multiple relays, or source the bunker relay from the operator's nostrclient relay config, is a real design question — tracked in #36.🤖 Generated with Claude Code