diff --git a/.release-please-manifest.json b/.release-please-manifest.json index f1c1e58..bcd0522 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.5.0" + ".": "0.6.0" } diff --git a/CHANGELOG.md b/CHANGELOG.md index f567b59..75434c0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,50 @@ ## [Unreleased] +## [0.6.0] - 2026-11-02 + +### Added + +- `mouse` CLI command, RPC and batch step for native click/drag/wheel input through libghostty-vt, with a new `mouse-input` capability and `CAPABILITY_UNAVAILABLE` (exit 12) when the native encoder is missing ([#179](https://github.com/coder/agent-tty/pull/179)). +- `wait --scope cursor-line` and matching `scope` field on batch wait steps / `waitForRender` RPC, so prompt waits like `--regex 'READY> $' --scope cursor-line` no longer match the terminal's echo of the typed command ([#169](https://github.com/coder/agent-tty/pull/169)). +- `record diff ` command that replays both sessions offline and emits a line-level diff, with `--at-seq-a`/`--at-seq-b` to diff a session against its own earlier state ([#170](https://github.com/coder/agent-tty/pull/170)). +- `screenshot --out ` writes the PNG to a chosen path, with the same path rules as `record export --out`; the capture is still published in-session ([#241](https://github.com/coder/agent-tty/pull/241)). +- `screenshot --json` now reports glyphs drawn as `.notdef` boxes in `result.missingGlyphs` (with cells and an optional `missingGlyphsTruncated` flag), so a harness can detect "screenshot incomplete" ([#240](https://github.com/coder/agent-tty/pull/240)). +- PTY processes now receive `AGENT_TTY_ACTIVE=true` and `AGENT_TTY_SESSION_ID=` so shell profiles and scripts can detect that they run inside a managed session ([#166](https://github.com/coder/agent-tty/pull/166), [#178](https://github.com/coder/agent-tty/pull/178)). + +### Changed + +- `wait` now defaults `--timeout` to 30 s (down from 600 s) and prints the default in `--help`; `--timeout 0` still waits forever, and `--idle-ms`/`--screen-stable-ms` of 30 s or more without an explicit `--timeout` is rejected with `INVALID_DURATION` ([#236](https://github.com/coder/agent-tty/pull/236)). +- Batch `wait` steps use the same 30 s default and reject a `screenStableMs` that cannot finish within it ([#250](https://github.com/coder/agent-tty/pull/250)). +- A timed-out `wait` and a fail-fast `batch` with a failed step now emit `ok: false` with `error.code: "WAIT_TIMEOUT"` (exit 11 unchanged); the existing `result.timedOut`/`result.matched`/`result.steps` fields remain ([#232](https://github.com/coder/agent-tty/pull/232)). +- Sessions default `COLORTERM=truecolor` so Neovim enables `termguicolors` without a wrapper; opt out with `create --env COLORTERM=` ([#231](https://github.com/coder/agent-tty/pull/231)). +- `snapshot`, `screenshot` and render waits now succeed on a session that has printed nothing, returning an empty screen or blank PNG with `capturedAtSeq: -1`; `wait --after-seq` accepts `-1` ([#235](https://github.com/coder/agent-tty/pull/235)). +- CLI startup warns on stderr when the running Node is outside `engines.node` (`>=24.0.0 <27`), and `doctor` checks against the same range ([#245](https://github.com/coder/agent-tty/pull/245)). + +### Fixed + +- Unexpected errors and invalid/empty session IDs now print a single `INTERNAL_ERROR` or `INVALID_SESSION_ID` JSON envelope on stdout instead of a raw Node stack; Commander usage errors under `--json` emit `INVALID_INPUT` ([#237](https://github.com/coder/agent-tty/pull/237)). +- `destroy` stops the program's process group (not just its pid), escalates to SIGKILL after a 2 s grace, and always ends in `recordDestroyed` instead of leaving sessions `failed` or `destroying` ([#194](https://github.com/coder/agent-tty/pull/194), [#201](https://github.com/coder/agent-tty/pull/201), [#216](https://github.com/coder/agent-tty/pull/216)). +- Every `destroy` kill now proves the program's process group through a per-session autogroup token (Linux), so a reused group id or an unrelated `setsid` group with a copied `AGENT_TTY_SESSION_ID` is never signalled ([#221](https://github.com/coder/agent-tty/pull/221), [#238](https://github.com/coder/agent-tty/pull/238)). +- `destroy` typed into the session's own shell is re-run in a new session, and off Linux the in-session check also compares the controlling terminal via `/bin/ps -o tty=` ([#216](https://github.com/coder/agent-tty/pull/216), [#246](https://github.com/coder/agent-tty/pull/246)). +- `destroy` survives an unreadable `/proc/self/stat` and a fork during the group scan, returning a proper envelope instead of exit 1 with a raw stack ([#233](https://github.com/coder/agent-tty/pull/233)). +- A `destroy --force` is no longer overwritten by a concurrent reconcile that reads the manifest first; a sticky `destroyed` marker makes the last write win ([#256](https://github.com/coder/agent-tty/pull/256)). +- `create` that gives up on an unreachable host now sends SIGTERM to that host, so a late-starting host no longer serves a session whose `create` failed ([#247](https://github.com/coder/agent-tty/pull/247)). +- Lifecycle races between concurrent `create`, `reconcile` and `gc` that could mark a starting session failed and then delete it, and host writes that could land after the exit record, are now serialized ([#181](https://github.com/coder/agent-tty/pull/181)). +- `allocateSession` validates `--cwd`, `--shell` and the command before creating the session directory, so a failed `create` no longer leaves an empty folder behind ([#188](https://github.com/coder/agent-tty/pull/188)). +- `writeManifest` no longer recreates a session folder that `gc` removed, and artifact writes keep a removed folder removed; `gc`'s `rm` retries past a late manifest write ([#200](https://github.com/coder/agent-tty/pull/200), [#212](https://github.com/coder/agent-tty/pull/212)). +- Repeat `screenshot`/`snapshot` captures at the same seq publish via `link` so a failed rollback can no longer delete an earlier file; differing bytes get a `-` suffix ([#191](https://github.com/coder/agent-tty/pull/191)). +- The Home Registry read now drops only invalid entries, so a single bad entry in `homes.json` no longer wipes every other registered Home on the next `create` ([#186](https://github.com/coder/agent-tty/pull/186)). +- A Home reached through a symlink resolves to the same canonical path before and after it exists, so the first `create` in a new symlinked Home no longer fails with `HOST_UNREACHABLE` ([#210](https://github.com/coder/agent-tty/pull/210)). +- The per-Home socket directory under `/tmp/agent-tty/` is removed once empty, and `listenInSocketDirectory` retries if the folder vanishes between `mkdir` and `bind` ([#239](https://github.com/coder/agent-tty/pull/239)). +- A waited `run` reserves its `input_run` seq synchronously with the PTY write, so the event log order matches what the child received; mouse input gets a dedicated renderer manager so same-cell motion dedup survives a renderer swap ([#234](https://github.com/coder/agent-tty/pull/234)). +- `validate-bundle --profile canonical` now rejects artifacts whose real path escapes the bundle root, and hero-demo `promote` leak-checks before writing ([#187](https://github.com/coder/agent-tty/pull/187)). +- A `doctor` PTY probe run from inside a session no longer inherits the outer session's `AGENT_TTY_SESSION_ID` ([#178](https://github.com/coder/agent-tty/pull/178)). + +### Dependencies + +- `@coder/libghostty-vt-node` upgraded from `0.1.0-beta.0` to `0.1.0-beta.5`. The `linux-x64` prebuild now runs on CPUs without AVX-512 (beta.4 crashed with SIGILL there); AVX2 is still required. Native snapshots inherit Ghostty v1.4.0 behavior ([#179](https://github.com/coder/agent-tty/pull/179)). + ## [0.5.0] - 2026-06-23 ### Added diff --git a/README.md b/README.md index 3a35b28..5694bb0 100644 --- a/README.md +++ b/README.md @@ -139,7 +139,7 @@ See [`docs/AGENT-SKILLS.md`](./docs/AGENT-SKILLS.md). ## Status & platform support -`agent-tty` is `0.5.0` and focused on reliable, isolated, reviewable terminal and TUI automation through a stable CLI. +`agent-tty` is `0.6.0` and focused on reliable, isolated, reviewable terminal and TUI automation through a stable CLI. - Linux and macOS are tier-1; Windows is tier-2 and not CI-tested. - Semantic snapshots and render-backed waits prefer the optional `libghostty-vt` backend when it is available, then fall back to `ghostty-web`. diff --git a/package.json b/package.json index 2a753d2..e52be0d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "agent-tty", - "version": "0.5.0", + "version": "0.6.0", "description": "Terminal automation CLI for AI agents and humans", "license": "Apache-2.0", "keywords": [