# What changed in bun-pty

> 12 changes in bun-pty 0.5 from its official release notes, upgrade guides and advisories: 5 breaking. Each one cited. Sources checked 2026-10-28. HTML: https://unstale.sh/npm/bun-pty/

To see which of these apply to a repository, run `npx @unstale/cli init` in it.

## bun-pty 0.5

### Breaking changes

- When the child inherits process.env on Unix, the parent's COLUMNS and LINES are dropped. (0.5.0) — [release notes](https://github.com/sursaone/bun-pty/releases/tag/v0.5.0)
- When provided, env replaces the child's environment instead of being merged with the parent's; spread process.env to inherit variables. (0.5.0) — [release notes](https://github.com/sursaone/bun-pty/releases/tag/v0.5.0)
- If env has no PATH, bare program names are still found using the parent's PATH, which is not passed to the child. (0.5.0) — [release notes](https://github.com/sursaone/bun-pty/releases/tag/v0.5.0)
- On Unix, PWD is set from cwd when building the child's environment. (0.5.0) — [release notes](https://github.com/sursaone/bun-pty/releases/tag/v0.5.0)
- When the child inherits process.env on Unix, the parent's tmux and screen variables are dropped. (0.5.0) — [release notes](https://github.com/sursaone/bun-pty/releases/tag/v0.5.0)

### Behavior and default changes

- Without env, the child receives the current process.env, so changes made at runtime reach it. (0.5.0) — [release notes](https://github.com/sursaone/bun-pty/releases/tag/v0.5.0)
- The name option is now optional, and env: process.env now type-checks. (0.5.0) — [release notes](https://github.com/sursaone/bun-pty/releases/tag/v0.5.0)

### Fixes and other changes

- Importing bun-pty no longer throws when no native library file is found; the error is deferred to spawn(), while the load failure is still logged at import. (0.5.2) — [release notes](https://github.com/sursaone/bun-pty/releases/tag/v0.5.2)
- When the native library fails to load, spawn() now throws a clear error containing the library path and dlopen error instead of an undefined-property error. (0.5.2) — [release notes](https://github.com/sursaone/bun-pty/releases/tag/v0.5.2)
- Test files are no longer included in the npm package, so consumers receive a package without src/*.test.ts files. (0.5.1) — [release notes](https://github.com/sursaone/bun-pty/releases/tag/v0.5.1)
- On Windows, an empty env map keeps the parent's environment. (0.5.0) — [release notes](https://github.com/sursaone/bun-pty/releases/tag/v0.5.0)
- On Unix, TERM is set from the name option, then from TERM in the environment, then to xterm. (0.5.0) — [release notes](https://github.com/sursaone/bun-pty/releases/tag/v0.5.0)
