base red: acpmux registers the Cloud turn methods and installs the TLS provider (#30337's own reds)

Closed
LA
4d ago
+21-0

Fixes the base red that #30337 left on feat-cmux-next: 5 of its own acpmux tests fail at the feat tip.

Summary

#30337 (cloud turn rewind client) merged at 10:32Z before its exact-head acpmux test run ended. Two causes, 5 reds:

  • agent-session-turn-prepare and agent-session-turn-abandon are served (server/requests.rs) and covered by the agent-session-turn-rewind-v1 capability, but not declared in protocol::registry(). Red: protocol::tests::protocol_registry_names_every_served_method, capabilities::tests::every_covered_name_is_in_the_protocol_registry.
  • CloudTurnClient::new builds a reqwest client with no rustls crypto provider installed ("No rustls crypto provider is configured"). Red: the 3 cloud_rewind::tests::preparation_*.

Changes:

  • protocol/mod.rs: declare both methods (untyped requests, like _acpmux/set_turn_cap).
  • cloud_rewind.rs: install the ring provider before the client is built, as mesh_http.rs, route_probe.rs and catalog/fetch.rs do.
  • Generated: spec/acpmux-protocol.json and webviews/.../protocol/generated/methods.ts (2 entries each).

How the generated files were made (repo generators, not hand edits):

  1. IR: protocol_ir_is_current (protocol/tests.rs) prints the fresh IR between BEGIN/END markers when it runs without write access. The fleet ci-step allowlist refuses ACPMUX_PROTOCOL_BLESS, so the file is that block, byte-for-byte (the log's 4-space capture indent removed), from fleet run 2a48cc82b675aa6805013d10 at 5b1c0390cdc. Proof that it equals ir_text(): protocol_ir_is_current passes at this head (run below). The equivalent local command is ACPMUX_PROTOCOL_BLESS=1 cargo test -p acpmux --lib protocol_ir_is_current.
  2. Web types: bun run acpmux-protocol:codegen in webviews/; bun run acpmux-protocol:check passes.

Testing

Focused command: scripts/ci/cmux-tui-rust-check.sh test <filter> on the fleet (macOS, isolated), filters protocol::, capabilities::, cloud_rewind::.

  • Red at feat 265c68a569a (the base): 8c5bf667f544ea404b8e418a (protocol_registry_names_every_served_method FAIL), 5cdda2e2785da5d36c8ccee4 (every_covered_name_is_in_the_protocol_registry FAIL), db3c63775b9e241201b0176b (3 preparation_* FAIL).
  • Green at 5b1c0390cdc (code fix): 28c24e4089d29baf6dd4353c capabilities 5/5, 1900477d153c7a03ec6a00f6 cloud_rewind 7/7; 2a48cc82b675aa6805013d10 protocol: only protocol_ir_is_current failed (stale IR, expected before step 1).
  • Green at this head (IR + types): protocol:: 890b171cb59bfca95fe81f51, clippy 3d88138e5fba177e04405af2 (results in a comment below).

Observed / Not run

  • Observed: the fleet runs above; bun run acpmux-protocol:check passes locally; the webviews bun run check reds (browser-lanes, design-tokens, type-scale, fmt, lint, vp check) are identical at base 265c68a569a and at this head, so they are base findings.
  • Not run: the full acpmux suite at this head (the change touches only the registry list, the provider install and generated files).

Changelog

none


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.


Summary by cubic

Fixes the base red that #30337 left on feat-cmux-next: 5 of its own acpmux tests fail because the Cloud turn methods were never registered in the protocol registry and the Cloud turn client builds its reqwest client without a rustls crypto provider.

  • Declares agent-session-turn-prepare and agent-session-turn-abandon in protocol::registry() alongside the other untyped requests.
  • Installs the ring rustls provider in CloudTurnClient::new before building the reqwest client, matching what mesh_http.rs, route_probe.rs, and catalog/fetch.rs do.
  • Regenerates spec/acpmux-protocol.json and the webview method types from the repo generators rather than by hand.

Migration

  • The generated files in spec/acpmux-protocol.json and webviews/src/agent-session/acpmux/protocol/generated/methods.ts were produced with the repository's own generators (ACPMUX_PROTOCOL_BLESS and bun run acpmux-protocol:codegen); no manual edits.