Files
codex/scripts/install
Eric Traut 615a8c98d6 Fix macOS standalone release pruning (#57503)
## Why

macOS `lsof +D` can return status 1 even when it finds open files, causing release cleanup to be skipped. It can also escape non-ASCII installation paths, preventing full-path matching from recognizing releases in use.

## What changed

Accept `lsof` status 1 while preserving matches, and continue to reject other failures or any stderr. Match the installer-owned ASCII path suffix on macOS and recognize processes whose working directory is the release root. Apply these checks before and after moving a release for deletion.

## Testing

Add coverage for `lsof` exit statuses, output, and errors. Exercise release retention with a non-ASCII installation path and, on macOS, a process holding the release directory open.

GitOrigin-RevId: 06181467c7d1bb256b6781241a444976b890d7c9
2026-10-27 16:21:43 +00:00
..