spirekeeper/tests
Padreug b55fc8bc1c
Some checks failed
ci.yml / fix(pairing): default bunker_relay to the spire's public event relay, not localhost (pull_request) Failing after 0s
fix(pairing): default bunker_relay to the spire's public event relay, not localhost
The seed minted via the Pair UI baked an unreachable bunker relay into
bunker_url. The UI form has no bunker_relay field, so pair_spire fell back to
its default `settings.lnbits_nsec_bunker_url` — which on a deployed instance is
the INTERNAL relay lnbits uses to reach the co-located bunker (e.g.
ws://127.0.0.1:5000/nostrrelay/demo). The remote ATM can't reach localhost, so
connectNewSeed hangs -> BunkerTimeoutError "Signer Unreachable". (Flagged by
bitspire on the demo; the localhost-relay /pair gotcha the coord thread called out.)

Default bunker_relay to the spire's own public event relay (relays[0]) instead:
the bunker lives on the same operator nostrrelay the spire publishes its events
to, so that URL is machine-reachable. An explicit `bunker_relay` still overrides
for split-relay deploys. An empty override now falls back to the same default
rather than raising.

Regression test: with no (or empty) bunker_relay, bunker_url embeds relays[0]
and contains no 127.0.0.1.

NOTE: relays[0] is a pragmatic default; whether the seed should carry multiple
relays / be sourced from the operator's nostrclient relay is a follow-up.
2026-06-22 17:18:24 +02:00
..
__init__.py feat: code quality 2024-08-13 08:20:45 +02:00
conftest.py refactor: rename extension identity to spirekeeper 2026-06-13 22:30:05 +02:00
test_calculations.py refactor(v2): canonical sat-amount vocabulary + delete Lamassu-era reverse-derivation 2026-05-26 20:08:30 +02:00
test_cassette_configs.py refactor: rename extension identity to spirekeeper 2026-06-13 22:30:05 +02:00
test_cassette_state_consumer.py chore(v2): lint pass — black + ruff auto-fix + mypy regressions (#29 v1.1) 2026-05-31 15:50:14 +02:00
test_collision_guard.py refactor: rename extension identity to spirekeeper 2026-06-13 22:30:05 +02:00
test_deposit_currency.py feat(v2): lock deposit currency to machine.fiat_code (closes #26) 2026-05-16 18:03:34 +02:00
test_fee_cap_validation.py feat(v2): CRUD + per-direction fee cap validation (#38 2/5) 2026-06-01 10:42:03 +02:00
test_fee_mismatch_recording.py refactor: rename extension identity to spirekeeper 2026-06-13 22:30:05 +02:00
test_fee_publish_triggers.py feat(v2): wire fee-config publish into machine + super-config triggers (#39 3/3) 2026-06-01 20:07:56 +02:00
test_fee_transport.py feat(v2): fee_transport — kind-30078 publisher for operator fee config (#39 2/3) 2026-06-01 20:00:29 +02:00
test_nip44_v2.py chore(v2): lint pass — black + ruff auto-fix + mypy regressions (#29 v1.1) 2026-05-31 15:50:14 +02:00
test_nostr_attribution.py refactor(v2): canonical sat-amount vocabulary + delete Lamassu-era reverse-derivation 2026-05-26 20:08:30 +02:00
test_operator_split_legs.py feat(v2): principal-based fee split — fixes super under-payment (#38 3/5) 2026-06-01 11:24:09 +02:00
test_pair_endpoint.py feat(pairing): optional token TTL + revoke endpoint (#9/#12, #22) 2026-06-18 18:51:54 +02:00
test_pairing.py fix(pairing): default bunker_relay to the spire's public event relay, not localhost 2026-06-22 17:18:24 +02:00
test_principal_based_fees.py feat(v2): principal-based fee split — fixes super under-payment (#38 3/5) 2026-06-01 11:24:09 +02:00
test_roster_resolver.py refactor: rename extension identity to spirekeeper 2026-06-13 22:30:05 +02:00
test_unpaired_machine_guards.py fix: complete the unpaired-machine sweep + regression test 2026-06-22 16:55:33 +02:00