Rebase onto the next upstream release (nostr-sdk relay layer, lnbits/nostrclient#70) #4
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
Why
Upstream
lnbits/nostrclientreplaced the websocket-client relay layer with nostr-sdk inae674ef(2026-07-13, PR #70, "fix: use nostr-sdk more without breaking changes — is much more stable"). Our fork point is the commit right before it (801ce44, upstream v1.2.0), so we still run the oldWebSocketApp+ thread-per-relay implementation plus our own reconnect patches on top of it.The old layer is the plausible home of lnbits/nwcprovider#53 (wallets time out after a transient upstream handshake failure until LNbits is restarted; closed there as not-planned because the defect is on the nostrclient side). We have not hit it on four84 yet, but the journal already shows the relay layer taking a minute-plus to recover from boot-time DNS failures.
Decision
Wait for an upstream release/tag that includes
ae674ef, then rebase onto that tag — not onto the bare commit. Rationale: the SDK rewrite touchedrelay_manager.py(+403),relay.py,key.py,event.py,helpers.py,tasks.py,views_api.py; picking an untagged mid-branch state gives us no stable base to name inv<upstream>-aio.N, and upstream may still adjust it before tagging.Fork commits to reconcile at rebase time
Run
git log v1.2.0..mainfor the authoritative list; the ones that interact with #70:ea9fc18"reconnect on on_close",49f206e"exponential delay for reconnect") — these patch the oldRelay/RelayManager. Expect to drop them: the SDK layer owns reconnection. Verify the SDK's behaviour on relay drop before deleting.v1.2.0-aio.2) —message_pool.pygainedCommandResultMessage;client.pyacallback_command_results_func;tasks.pythe pump;router.pythePendingPublishtracking. Upstream #70 did not touchmessage_pool.pyorrouter.py, but it rewroterelay_manager.py, which is what feeds the pool. Check that relayOKmessages still reachMessagePool.add_messageunder the SDK layer, otherwise clients getOK falseon timeout for every publish.tests/test_router_ok.pycovers the router half; add a pool-feed test if the SDK path differs.git log v1.2.0..mainthat is not a version/catalog bump.Checklist
ae674efexists: ______git fetch upstream && git rebase <tag>on a branch; resolve the three areas abovegh pr list -R lnbits/nostrclient --state allfor anything else that overlapstests/(see workspace CLAUDE.md for the bohm venv workaround)nwcsim3.py-style: provider subscribed to its own kind-23195 replies)v<upstream>-aio.1, add catalog entry (keep1.2.0-aio.2)docs/upstream-candidates.mdif the OK-reply work is worth proposing upstreamRelated
v1.2.0-aio.2)v1.1.0-aio.3); the actual cause of the Amethyst NWC timeouts, unrelated to #70 but found in the same investigation🤖 Generated with Claude Code
https://claude.ai/code/session_013Tbyw6FwjhEJg3gHfPHxWt