Remove literal-address -s dialling; keep only -s mdns: discovery - #56
Merged
chrisuthe merged 1 commit intoSep 15, 2026
Merged
Conversation
The spec has a player connect only to a server it discovers, so a typed-in host, host:port or ws:// URL is now a parse error (from a config file too) that names the removal and never quotes the value. parse_server_url() and redact_url_userinfo() go with it.
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
The implementation consistently removes literal-address dialing while preserving and testing mDNS discovery behavior.
Pull request overview
Removes literal server dialing and restricts outbound connections to mDNS-discovered servers.
Changes:
- Rejects non-
mdns:server values without exposing them. - Simplifies outbound dialing and URL tracking.
- Updates tests, documentation, examples, and packaging comments.
File summaries
| File | Description |
|---|---|
src/cli.cpp |
Enforces discovery-only server parsing. |
src/cli.h |
Removes literal-address APIs and state. |
src/main.cpp |
Always uses discovery for outbound mode. |
src/outbound.cpp |
Rejects unverifiable dial records. |
src/outbound.h |
Updates LastDial contract. |
src/mdns_common.cpp |
Updates IPv6 URL comment. |
src/hooks.h |
Documents discovery-only URL export. |
src/audio_sink.cpp |
Removes obsolete parser reference. |
tests/cli_test.cpp |
Tests address rejection and secrecy. |
tests/config_file_test.cpp |
Tests configuration behavior. |
tests/discovery_test.cpp |
Tests updated LastDial semantics. |
scripts/smoke_test.sh |
Removes obsolete redaction test. |
README.md |
Documents mDNS-only usage. |
packaging/sendspin-cli.service.in |
Updates service comment. |
packaging/sendspin-cli.conf.example |
Updates configuration example. |
docs/wiki/Troubleshooting.md |
Updates no-mDNS guidance. |
docs/wiki/Home.md |
Describes discovery-based outbound mode. |
docs/wiki/Getting-Started-on-Linux.md |
Updates setup instructions. |
docs/wiki/Controlling-the-Player.md |
Clarifies exported server URL semantics. |
docs/wiki/Configuration.md |
Documents accepted server values. |
docs/wiki/Advanced-Usage.md |
Removes address-dialing examples. |
docs/ROADMAP.md |
Records the shipped breaking change. |
Review details
- Files reviewed: 22/22 changed files
- Comments generated: 0
- Review effort level: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
chrisuthe
marked this pull request as ready for review
September 15, 2026 18:47
chrisuthe
added a commit
that referenced
this pull request
Sep 17, 2026
The 'What the scaffold already does' line still said -s dials a literal address; #56 removed that. Item 5 and item 26 stay as the historical record.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Sendspin spec has two ways to connect: the server discovers the player's
_sendspin._tcpadvertisement, or the player discovers a server on_sendspin-server._tcpand connects to it. Dialling a typed-inhost[:port]orws://URL is neither, so-s/server =now take onlymdns:[<name>].Breaking: any other
-sorservervalue (host, host:port, ws:// URL, baremdns, empty) exits 1 at parse time with oneerror:line that says address dialling was removed and points to-s mdns:[<name>]or being discovered. From a config file it names the file and line. The value is never echoed, since it may hold credentials.parse_server_url(),redact_url_userinfo(),USERINFO_MASK,DEFAULT_REMOTE_SERVER_PORTandOptions::server_urlOutboundModealways dials a discovered server;LastDialanswers nothing for an empty server_id--help, the no-mDNS parse error and the no-mDNS runtime line no longer offer an address-s mdns:behaviour is unchanged: the advertisement is suppressed, browsing and last-server preference work as before, the retry backoff still applies, andSENDSPIN_SERVER_URLis still exported for the dialled server.Testing
-DSENDSPIN_CLI_WITH_MDNS=OFFbuild: 416/416 unit testsscripts/smoke_test.sh: every check passed-s "mdns:Living Room"browses and finds servers on the LAN