[GH-ISSUE #7420] [Bug] Runtime-settings guide incorrectly says setup omits the response-byte budget #4427

Closed
opened 2026-10-31 00:49:43 +00:00 by bsakaguchi · 1 comment
Owner

Originally created by @coygeek on GitHub (Oct 27, 2026).
Original GitHub issue: https://github.com/morluto/rea/issues/7420

Before submitting

  • I searched the open and closed issues for a related report.
  • I removed credentials, tokens, private paths, and sensitive target data.

Area

Documentation

Observed behavior

Reading the runtime-settings design guide gives maintainers incorrect guidance about registering a selected MCP response budget. Its response-budget example says setup does not copy the setting, while the client guide says setup forwards it. Independent source inspection confirms that the production setup path selects and carries this value into registration planning. The existing focused test passed with a 20971520-byte selection. This verification did not execute the CLI dry run or write a client registration.

Reproduction

Use a fresh REA checkout at commit f8f7ac96de with Node.js 24.22.1 and the locked dependencies installed using npm ci. From the repository root, inspect the contradictory passages and run the existing source test:

sed -n '120,126p' docs/design/limits-and-recovery.md
sed -n '270,279p' docs/client-configuration.md
sed -n '70,95p' src/application/SetupRegistrationEnvironment.ts
npm run test:local -- src/mcpStartupPolicy.test.ts

The design paragraph says the setup allowlist does not copy the response-budget setting. The client guide explicitly lists it among forwarded selections, and the allowlist includes it. The test run independently passed all six cases, including the assertion that an explicit REA_MCP_MAX_RESPONSE_BYTES=20971520 survives selection. This is a source-confirmed documentation contradiction; no binary, provider, or target fixture is required.

Expected behavior

The design guide should say that setup forwards an explicitly selected REA_MCP_MAX_RESPONSE_BYTES. Expected source: docs/client-configuration.md:270 names the setting among forwarded selections, and src/application/SetupRegistrationEnvironment.ts:74 includes it in the allowlist consumed by src/application/SetupRegistrationEnvironment.ts:87. The guide should agree with this documented and tested behavior.

Impact and scope

P3: incorrect wording in a maintainer-facing design guide, with no consequential runtime failure demonstrated. A reader may incorrectly conclude that setup cannot preserve a selected response budget. The current implementation and client guide already provide the correct behavior and explanation. The demonstrated scope is this paragraph; no failed analysis, lost configuration, or blocked core workflow was observed.

REA version

rea-agents 6.8.0 from package metadata; baseline commit f8f7ac96de.

Runtime and platform

Node.js v24.22.1; macOS 27.0.1; Darwin kernel 27.0.0; arm64. No analysis provider was required.

Target and artifact context

Not applicable: documentation inspection and an existing source test for setup environment selection.

Interface

Package or setup

Earliest failure stage

Unknown

Relevant output or evidence

Failure source: docs/design/limits-and-recovery.md:125 says the setup allowlist does not copy the setting discussed immediately above. Expected source: docs/client-configuration.md:270 explicitly promises forwarding. Implementation source: src/application/SetupRegistrationEnvironment.ts:74 selects the setting, and src/application/SetupRegistrationEnvironment.ts:87 copies defined selected values.

Production reachability is source-derived: src/cli/setupCommands.ts:235 invokes setup with the selected environment; src/application/SetupHost.ts:237 merges explicit selections into the setup provider environment; src/application/SetupPlan.ts:351 passes that environment into action details; src/application/SetupPlan.ts:439 renders each entry. The setting is not conditional on an available analysis provider at the selection boundary.

Observed focused-test output from the reproduction command:

Test Files  1 passed (1)
Tests       6 passed (6)

The relevant assertion is in src/mcpStartupPolicy.test.ts:70: the supplied response-budget value is retained while unrelated settings are omitted. This test result establishes environment selection; the CLI planning path above was checked statically.

Typed outcome or recovery expected

Update the design paragraph to reflect that setup forwards the explicitly selected response-byte budget. No runtime error or behavior change is required by the demonstrated defect.

Additional context

Verification was limited to the stated commit and local evidence; the CLI dry run was not executed. The same sentence is still present on the current default branch at the time of filing.

Originally created by @coygeek on GitHub (Oct 27, 2026). Original GitHub issue: https://github.com/morluto/rea/issues/7420 ### Before submitting - [x] I searched the open and closed issues for a related report. - [x] I removed credentials, tokens, private paths, and sensitive target data. ### Area Documentation ### Observed behavior Reading the runtime-settings design guide gives maintainers incorrect guidance about registering a selected MCP response budget. Its response-budget example says setup does not copy the setting, while the client guide says setup forwards it. Independent source inspection confirms that the production setup path selects and carries this value into registration planning. The existing focused test passed with a 20971520-byte selection. This verification did not execute the CLI dry run or write a client registration. ### Reproduction Use a fresh REA checkout at commit f8f7ac96de8a66a4ab9a23d87e04779bfcd11045 with Node.js 24.22.1 and the locked dependencies installed using `npm ci`. From the repository root, inspect the contradictory passages and run the existing source test: ```sh sed -n '120,126p' docs/design/limits-and-recovery.md sed -n '270,279p' docs/client-configuration.md sed -n '70,95p' src/application/SetupRegistrationEnvironment.ts npm run test:local -- src/mcpStartupPolicy.test.ts ``` The design paragraph says the setup allowlist does not copy the response-budget setting. The client guide explicitly lists it among forwarded selections, and the allowlist includes it. The test run independently passed all six cases, including the assertion that an explicit `REA_MCP_MAX_RESPONSE_BYTES=20971520` survives selection. This is a source-confirmed documentation contradiction; no binary, provider, or target fixture is required. ### Expected behavior The design guide should say that setup forwards an explicitly selected `REA_MCP_MAX_RESPONSE_BYTES`. Expected source: `docs/client-configuration.md:270` names the setting among forwarded selections, and `src/application/SetupRegistrationEnvironment.ts:74` includes it in the allowlist consumed by `src/application/SetupRegistrationEnvironment.ts:87`. The guide should agree with this documented and tested behavior. ### Impact and scope P3: incorrect wording in a maintainer-facing design guide, with no consequential runtime failure demonstrated. A reader may incorrectly conclude that setup cannot preserve a selected response budget. The current implementation and client guide already provide the correct behavior and explanation. The demonstrated scope is this paragraph; no failed analysis, lost configuration, or blocked core workflow was observed. ### REA version rea-agents 6.8.0 from package metadata; baseline commit f8f7ac96de8a66a4ab9a23d87e04779bfcd11045. ### Runtime and platform Node.js v24.22.1; macOS 27.0.1; Darwin kernel 27.0.0; arm64. No analysis provider was required. ### Target and artifact context Not applicable: documentation inspection and an existing source test for setup environment selection. ### Interface Package or setup ### Earliest failure stage Unknown ### Relevant output or evidence Failure source: `docs/design/limits-and-recovery.md:125` says the setup allowlist does not copy the setting discussed immediately above. Expected source: `docs/client-configuration.md:270` explicitly promises forwarding. Implementation source: `src/application/SetupRegistrationEnvironment.ts:74` selects the setting, and `src/application/SetupRegistrationEnvironment.ts:87` copies defined selected values. Production reachability is source-derived: `src/cli/setupCommands.ts:235` invokes setup with the selected environment; `src/application/SetupHost.ts:237` merges explicit selections into the setup provider environment; `src/application/SetupPlan.ts:351` passes that environment into action details; `src/application/SetupPlan.ts:439` renders each entry. The setting is not conditional on an available analysis provider at the selection boundary. Observed focused-test output from the reproduction command: ```text Test Files 1 passed (1) Tests 6 passed (6) ``` The relevant assertion is in `src/mcpStartupPolicy.test.ts:70`: the supplied response-budget value is retained while unrelated settings are omitted. This test result establishes environment selection; the CLI planning path above was checked statically. ### Typed outcome or recovery expected Update the design paragraph to reflect that setup forwards the explicitly selected response-byte budget. No runtime error or behavior change is required by the demonstrated defect. ### Additional context Verification was limited to the stated commit and local evidence; the CLI dry run was not executed. The same sentence is still present on the current default branch at the time of filing.
Author
Owner

@chordpli commented on GitHub (Oct 31, 2026):

I would like to take this one. Still present on main at 60149282f: docs/design/limits-and-recovery.md says the setup allowlist does not copy REA_MCP_MAX_RESPONSE_BYTES, but it is in SELECTED_REGISTRATION_SETTINGS, and a built-CLI rea setup --client codex --dry-run with REA_MCP_MAX_RESPONSE_BYTES=20971520 plans Detected provider environment: REA_MCP_MAX_RESPONSE_BYTES=20971520 in the registration (unset: not listed). I will open a docs-only PR that corrects the paragraph.

<!-- gh-comment-id:6546115871 --> @chordpli commented on GitHub (Oct 31, 2026): I would like to take this one. Still present on `main` at `60149282f`: `docs/design/limits-and-recovery.md` says the setup allowlist does not copy `REA_MCP_MAX_RESPONSE_BYTES`, but it is in `SELECTED_REGISTRATION_SETTINGS`, and a built-CLI `rea setup --client codex --dry-run` with `REA_MCP_MAX_RESPONSE_BYTES=20971520` plans `Detected provider environment: REA_MCP_MAX_RESPONSE_BYTES=20971520` in the registration (unset: not listed). I will open a docs-only PR that corrects the paragraph.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
morluto/rea#4427
No description provided.