Skip to content

test: regression guard for rent(mode=...) WS forwarding (task 399)#4

Merged
iWedmak merged 1 commit into
masterfrom
feat/399-mode-regression-tests
Jun 4, 2026
Merged

test: regression guard for rent(mode=...) WS forwarding (task 399)#4
iWedmak merged 1 commit into
masterfrom
feat/399-mode-regression-tests

Conversation

@iWedmak

@iWedmak iWedmak commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds a regression test that locks the WS wire format for rent(mode=...) — guards against silent renames or accidental drops on the mode field travelling from SDK call through to the relay rent_requested payload.

  • Test-only change, no production code touched.
  • No version bump, no publish.

Test plan

  • regression test passes locally
  • CI green

Diagnosed by main on 2026-06-04: CLI 'ceki rent --mode main' and SDK
client.rent(mode='main') were reported not forwarding the flag to
POST /api/sessions. Investigation showed _client.rent() already puts
mode in the WS rent payload (_client.py:187), the CLI already passes
args.mode to client.rent() (cli.py:73), the relay schema already
validates + forwards it to back (browser-relay agentRouter
rentSchema/handleRent), and back's SessionController honors it. So
end-to-end is wired — the original report was traced to an older SDK
version pinned on the calling side (PyPI has 2.17.1; 2.15.1 was
installed somewhere).

Lock the wire format with an explicit test so any future refactor that
drops the mode field from the rent message fails CI immediately.

Refs: task 399 / #310
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