Skip to content

Report relay connection errors when no relay is reachable - #46

Merged
mattn merged 1 commit into
mainfrom
fix/report-relay-connect-error
Nov 19, 2026
Merged

mattn merged 1 commit into
mainfrom
fix/report-relay-connect-error

Conversation

@mattn

@mattn mattn commented Nov 19, 2026

Copy link
Copy Markdown
Owner

With the network down (e.g. Wi-Fi off), commands printed nothing (timeline etc.) or just cannot post.

  • The pool's subscription helpers silently skip relays they cannot connect to. Add connectRelays to connect up front in QueryEvents / StreamEvents / StreamLive and fail with per-relay errors when none connect.
  • timeline now propagates the StreamEvents error; StreamLive returns an error.
  • Do prints connection errors to stderr when no relay connected, even without verbose.

Partial failures are still reported only in verbose mode.

The pool's subscription helpers silently skip relays they cannot connect
to, and Do only printed connection errors in verbose mode, so with the
network down (e.g. Wi-Fi off) commands printed nothing or just
"cannot post". Connect to relays up front and fail with the per-relay
errors when none connect, and propagate StreamEvents/StreamLive errors.
@mattn
mattn merged commit 14d9456 into main Nov 19, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant