Skip to content

fix: normalize Pi ACP bootstrap payloads#227

Merged
NathanFlurry merged 5 commits into
mainfrom
NathanFlurry/pi-bootstrap-fix
Mar 16, 2026
Merged

fix: normalize Pi ACP bootstrap payloads#227
NathanFlurry merged 5 commits into
mainfrom
NathanFlurry/pi-bootstrap-fix

Conversation

@NathanFlurry

@NathanFlurry NathanFlurry commented Mar 10, 2026

Copy link
Copy Markdown
Member

Summary

  • normalize Pi ACP initialize requests by coercing string protocolVersion values to JSON numbers before forwarding
  • normalize Pi ACP session/new requests by ensuring params.mcpServers defaults to [] when omitted
  • add a regression test using a strict Pi stub that fails without these normalizations
  • document custom Pi binary configuration in CLI docs (PI_ACP_PI_COMMAND, PATH, and symlink strategies)
  • update quickstart docs to list all supported agent IDs and include pi/cursor in preinstall examples

Why

Pi ACP bootstrap could fail end-to-end when callers sent protocolVersion as a string and/or omitted mcpServers in session/new.

Separately, users running forked/custom Pi binaries need documented override options for how pi-acp resolves the pi command, and quickstart should clearly list the supported agents.

Testing

  • cargo test -p sandbox-agent --test v1_api acp_transport::pi_initialize_and_session_new_are_normalized -- --nocapture
  • cargo test -p sandbox-agent --test v1_api -- --nocapture

@railway-app
railway-app Bot temporarily deployed to sandbox-agent / sandbox-agent-pr-227 March 10, 2026 03:42 Destroyed
@railway-app

railway-app Bot commented Mar 10, 2026

Copy link
Copy Markdown

🚅 Deployed to the sandbox-agent-pr-227 environment in sandbox-agent

Service Status Web Updated (UTC)
website ✅ Success (View Logs) Web Mar 16, 2026 at 1:52 am

@railway-app
railway-app Bot temporarily deployed to sandbox-agent / sandbox-agent-pr-227 March 16, 2026 01:21 Destroyed
@railway-app
railway-app Bot temporarily deployed to sandbox-agent / sandbox-agent-pr-227 March 16, 2026 01:23 Destroyed
@railway-app
railway-app Bot temporarily deployed to sandbox-agent / sandbox-agent-pr-227 March 16, 2026 01:47 Destroyed
@railway-app
railway-app Bot temporarily deployed to sandbox-agent / sandbox-agent-pr-227 March 16, 2026 01:52 Destroyed
@NathanFlurry
NathanFlurry merged commit d850a3b into main Mar 16, 2026
3 of 4 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