Sean Huang
09db085f94
Support negotiated server-side truncation in Code Mode clients ( #58125 )
...
## Why
Host-side truncation can bound Code Mode output before it crosses the transport, including script errors that would otherwise exceed the frame limit.
## What changed
- Negotiate server-side output truncation for stdio and gRPC sessions, with client-side fallback for older hosts.
- Forward output budgets for execution, waiting, and termination when server-side truncation is selected. Avoid truncating host-formatted output or appending script errors a second time.
- Preserve the negotiated mode across reconnects and reject hosts that cannot maintain it.
## Testing
Add transport and integration coverage for output budgets, oversized script errors, reconnect compatibility, and preservation of output-limit notices with a zero-token budget.
GitOrigin-RevId: 2075101e4845eca64f45491c27a3b326788645c8
2026-10-29 16:57:12 +00:00
..
2026-10-29 15:55:50 +00:00
2026-10-27 05:52:01 +00:00
2026-10-23 14:59:40 +00:00
2026-10-29 11:23:51 +00:00
2026-10-29 16:30:06 +00:00
2026-10-29 11:23:51 +00:00
2026-10-27 18:35:19 +00:00
2026-10-29 16:30:06 +00:00
2026-10-29 11:23:51 +00:00
2026-10-26 20:02:45 +00:00
2026-10-27 22:02:35 +00:00
2026-10-26 20:26:32 +00:00
2026-10-27 22:59:22 +00:00
2026-10-22 19:36:47 +00:00
2026-10-27 17:04:16 +00:00
2026-10-26 21:08:15 +00:00
2026-10-29 11:23:51 +00:00
2026-10-26 18:06:07 +00:00
2026-10-26 18:14:57 +00:00
2026-10-20 15:43:19 +00:00
2026-10-29 16:57:12 +00:00
2026-10-29 16:57:12 +00:00
2026-10-29 01:04:48 +00:00
2026-10-29 01:04:48 +00:00
2026-10-29 12:54:39 +00:00
2026-10-19 21:43:19 +00:00
2026-10-29 03:47:52 +00:00
2026-10-29 11:23:51 +00:00
2026-10-27 22:01:13 +00:00
2026-10-26 21:55:00 +00:00
2026-10-29 16:57:12 +00:00
2026-10-27 19:50:41 +00:00
2026-10-19 15:15:17 +00:00
2026-10-28 20:12:18 +00:00
2026-10-27 05:52:01 +00:00
2026-10-26 19:19:10 +00:00
2026-10-29 11:23:51 +00:00
2026-10-29 08:51:18 +00:00
2026-10-28 21:09:05 +00:00
2026-10-27 23:53:09 +00:00
2026-10-29 11:23:51 +00:00
2026-10-29 12:54:39 +00:00
2026-10-28 21:22:06 +00:00
2026-10-29 16:41:12 +00:00
2026-10-22 19:36:47 +00:00
2026-10-22 19:36:47 +00:00
2026-10-27 23:53:09 +00:00
2026-10-26 20:40:53 +00:00
2026-10-29 16:46:01 +00:00
2026-10-27 19:50:41 +00:00
2026-10-26 19:21:08 +00:00
2026-10-28 13:55:51 +00:00
2026-10-22 19:36:47 +00:00
2026-10-26 18:31:21 +00:00
2026-10-29 16:39:38 +00:00
2026-10-29 10:34:17 +00:00
2026-10-22 19:36:47 +00:00
2026-10-23 15:00:06 +00:00
2026-10-22 19:36:47 +00:00
2026-10-29 16:39:38 +00:00
2026-10-28 00:51:29 +00:00
2026-10-28 17:04:31 +00:00
2026-10-29 04:28:05 +00:00
2026-10-26 18:22:40 +00:00
2026-10-29 10:34:17 +00:00
2026-10-27 16:36:32 +00:00
2026-10-27 23:53:34 +00:00
2026-10-29 11:23:51 +00:00
2026-10-27 13:31:38 +00:00
2026-10-19 16:56:42 +00:00
2026-10-29 03:47:52 +00:00
2026-10-27 19:50:41 +00:00
2026-10-28 01:29:34 +00:00
2026-10-28 00:51:29 +00:00
2026-10-27 05:52:01 +00:00
2026-10-27 05:52:01 +00:00
2026-10-22 04:59:19 +00:00
2026-10-27 05:52:01 +00:00
2026-10-19 21:01:44 +00:00
2026-10-28 21:22:06 +00:00
2026-10-22 00:19:02 +00:00
2026-10-28 01:04:30 +00:00
2026-10-27 19:50:41 +00:00
2026-10-28 04:05:31 +00:00
2026-10-27 14:14:16 +00:00
2026-10-29 11:23:51 +00:00
2026-10-29 01:04:48 +00:00
2026-10-28 20:57:54 +00:00
2026-10-27 05:52:01 +00:00
2026-10-27 05:52:01 +00:00
2026-10-28 11:48:00 +00:00
2026-10-28 06:24:24 +00:00
2026-10-26 22:05:00 +00:00
2026-10-28 21:09:05 +00:00
2026-10-29 03:47:52 +00:00
2026-10-28 07:12:32 +00:00
2026-10-29 15:55:50 +00:00
2026-10-27 05:52:01 +00:00