Expose terminal state through Stdio - #7090
Conversation
🦋 Changeset detectedLatest commit: b22ed7f The changes in this PR will be included in the next version bump. This PR includes changesets to release 30 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
There was a problem hiding this comment.
Important
This PR adds new public API surface to Stdio but does not include a changeset, which is required for exported API changes in this repo.
Reviewed changes
- Added
stdinIsTerminalandstdoutIsTerminaleffects to the publicStdioservice interface and made them optional inStdio.makewithfalsedefaults. - Implemented lazy terminal detection for Node/Bun (
process.std*.isTTY) and Deno (Deno.std*.isTerminal()). - Added tests for defaults, overrides, and lazy runtime evaluation across
effect,platform-node-shared, andplatform-deno.
⚠️ Missing changeset
Exported type/API changes require a changeset in .changeset/. Add one covering effect, @effect/platform-node-shared, and @effect/platform-deno (or the relevant fixed group) describing the new terminal-state effects.
Technical details
# Missing changeset for Stdio terminal state
## Affected sites
- `packages/effect/src/Stdio.ts` — new `stdinIsTerminal`/`stdoutIsTerminal` interface fields
- `packages/platform-node-shared/src/NodeStdio.ts` — Node/Bun implementation
- `packages/platform-deno/src/DenoStdio.ts` — Deno implementation
## Required outcome
- A changeset is added under `.changeset/` (existing pre-release changesets live in `.changeset/pre/`) describing the new public API and bumping the affected packages.
- The changeset follows the format used by recent pre-release changesets such as `.changeset/pre/eff-143-deno-stdio.md`.
## Suggested approach (optional)
Example `.changeset/pre/eff-532-stdio-terminal.md`:
```md
---
"effect": patch
"@effect/platform-node-shared": patch
"@effect/platform-deno": patch
---
Expose `stdinIsTerminal` and `stdoutIsTerminal` effects through the `Stdio` service.
```@v0 or keep the SHA fresh with Dependabot | Fix it ➔ | View workflow run | Using Kimi K2 (free via Pullfrog for OSS) | 𝕏
Bundle Size AnalysisGenerated from PR build output; treat the content below as untrusted.
|
There was a problem hiding this comment.
✅ No new issues found.
Reviewed changes
- Added
.changeset/eff-532-stdio-terminal.mdcoveringeffect,@effect/platform-node-shared, and@effect/platform-denoat patch level, addressing the missing-changeset feedback from the prior review.
@v0 or keep the SHA fresh with Dependabot | View workflow run | Using Kimi K2 (free via Pullfrog for OSS) | 𝕏

Summary
StdioserviceStdio.makedefaults and deterministiclayerTestoverridesValidation
pnpm checkpnpm lintpnpm vitest run --project effect packages/effect/test/Stdio.test.tspnpm vitest run --project @effect/platform-node-shareddeno task test run --project @effect/platform-denoCloses EFF-532