Skip to content

docs(cli): teach the .sock rule instead of the deprecated --port 0 Unix-socket spelling #1631

Closed

Description

@agatha197

Summary

The --host/--port help text (in both binaries) and docs/python-client.md still teach the deprecated --port 0 Unix-socket spelling. The current rule is the .sock suffix on --host, and the old form emits a deprecation warning at runtime.

Background

All four flag doc-comments read:

/// Host address to bind to (or Unix socket path when --port 0)
/// Port number to listen on (0 = Unix socket mode using --host as socket path)
  • src/main.rs:1172,1176
  • src/bin/mlx_server.rs:403,407

Ground truth is in src/server/transport.rs: the selection rule is "--host ending in .sock is a Unix domain socket path, whatever --port says" (the b10621 rule, transport.rs:107), and the --port 0 form emits a deprecation warning (transport.rs:98,133-138). In docs, README.md:115 already uses the new spelling, but docs/python-client.md:61-62 still explains the old rule ("--port 0 reinterprets --host as the socket path") and :81 repeats it.

Proposed Solution

Rewrite the four doc-comments and the two python-client.md passages around the .sock rule, mentioning --port 0 only as a deprecated alias if at all.

Implementation Notes

  • These are six one-line text edits with no logic change.

Acceptance Criteria

  • --help for both binaries describes the .sock rule as primary.
  • docs/python-client.md no longer teaches --port 0 as the rule.

Original Suggestion

Title: docs(cli): --host/--port help text still teaches the deprecated --port 0 Unix-socket spelling

The --host/--port help text (in both binaries) and docs/python-client.md still teach the deprecated --port 0 Unix-socket spelling. The current rule is the .sock suffix on --host, and the old form emits a deprecation warning at runtime.

Evidence

All four flag doc-comments read:

/// Host address to bind to (or Unix socket path when --port 0)
/// Port number to listen on (0 = Unix socket mode using --host as socket path)
  • src/main.rs:1172,1176
  • src/bin/mlx_server.rs:403,407

Ground truth: src/server/transport.rs:103-140 — rule 1 is "--host ending in .sock is a Unix domain socket path, whatever --port says. This is the b10621 rule and the spelling to use", and the --port 0 form emits a deprecation warning (transport.rs:133-138).

Docs: README.md:115 already uses the new spelling, but docs/python-client.md:61-62 still explains the old rule ("--port 0 reinterprets --host as the socket path") and :81 repeats it.

Suggested fix

Rewrite the four doc-comments and the two python-client.md passages around the .sock rule, mentioning --port 0 only as a deprecated alias if at all. Six one-line text edits.

Acceptance criteria

  • --help for both binaries describes the .sock rule as primary
  • docs/python-client.md no longer teaches --port 0 as the rule

Activity

  1. changed the title [-]docs(cli): --host/--port help text still teaches the deprecated --port 0 Unix-socket spelling[/-] [+]docs(cli): teach the .sock rule instead of the deprecated --port 0 Unix-socket spelling[/+] on Sep 4, 2026
  2. added 2 commits that reference this issue on Sep 5, 2026
    7020f89
    9bef3f2
  3. added a commit that references this issue on Sep 6, 2026
    998b2e0
  4. added a commit that references this issue on Sep 6, 2026
    05732c3
  5. added and removed on Sep 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions