Description
tests/e2e/helpers.ts defines runCli as a promisify(execFile) wrapper over dist/src/main.js. It does not pass an explicit maxBuffer, so it inherits the Node default of 1 MB. On v1.8.2 opencli list -f json emits 1,067,516 bytes (node dist/src/main.js list -f json | wc -c), so the child process overflows the default buffer and execFile rejects with code: 'ERR_CHILD_PROCESS_STDIO_MAXBUFFER'. runCli's catch returns that string as the result code, so the assertion expect(code).toBe(0) fails with the literal string 'ERR_CHILD_PROCESS_STDIO_MAXBUFFER' instead of 0. Same root cause on both Linux and macOS in the main E2E Headed Chrome workflow.
Steps to Reproduce
- Build main:
npm run build
- Measure the current
list -f json size: node dist/src/main.js list -f json | wc -c returns ~1,067,516 (just past the 1,048,576-byte default maxBuffer).
- Run the E2E test:
npx vitest run tests/e2e/management.test.ts -t "list shows all registered commands".
- Observe failure:
AssertionError: expected 'ERR_CHILD_PROCESS_STDIO_MAXBUFFER' to be +0.
Same failure trace appears at tests/e2e/output-formats.test.ts for list -f json. yaml / csv / md formats happen to stay under 1 MB so they pass.
Expected Behavior
runCli(['list', '-f', 'json']) returns { code: 0, stdout: <full json> } regardless of manifest size. The helper should not silently truncate / error on large CLI outputs as new adapters land.
OpenCLI Version
1.8.2
Node.js Version
22.x
Operating System
Other
Logs / Screenshots
× tests/e2e/management.test.ts > management commands E2E > list shows all registered commands
> expected 'ERR_CHILD_PROCESS_STDIO_MAXBUFFER' to be +0
× tests/e2e/output-formats.test.ts > output formats E2E > list -f json produces valid output
> expected 'ERR_CHILD_PROCESS_STDIO_MAXBUFFER' to be +0
(both fail on ubuntu-latest and macos-latest in workflow "E2E Headed Chrome" on sha ec3eddec / chore(release): 1.8.2)
Description
tests/e2e/helpers.tsdefinesrunClias apromisify(execFile)wrapper overdist/src/main.js. It does not pass an explicitmaxBuffer, so it inherits the Node default of 1 MB. On v1.8.2opencli list -f jsonemits 1,067,516 bytes (node dist/src/main.js list -f json | wc -c), so the child process overflows the default buffer andexecFilerejects withcode: 'ERR_CHILD_PROCESS_STDIO_MAXBUFFER'.runCli's catch returns that string as the resultcode, so the assertionexpect(code).toBe(0)fails with the literal string'ERR_CHILD_PROCESS_STDIO_MAXBUFFER'instead of0. Same root cause on both Linux and macOS in the main E2E Headed Chrome workflow.Steps to Reproduce
npm run buildlist -f jsonsize:node dist/src/main.js list -f json | wc -creturns ~1,067,516 (just past the 1,048,576-byte defaultmaxBuffer).npx vitest run tests/e2e/management.test.ts -t "list shows all registered commands".AssertionError: expected 'ERR_CHILD_PROCESS_STDIO_MAXBUFFER' to be +0.Same failure trace appears at
tests/e2e/output-formats.test.tsforlist -f json. yaml / csv / md formats happen to stay under 1 MB so they pass.Expected Behavior
runCli(['list', '-f', 'json'])returns{ code: 0, stdout: <full json> }regardless of manifest size. The helper should not silently truncate / error on large CLI outputs as new adapters land.OpenCLI Version
1.8.2
Node.js Version
22.x
Operating System
Other
Logs / Screenshots