{"version":"2.1.336","anchor":"macos-version-cleanup-now-keeps-versions-that-running-daemon","canonical_anchor":"macos-version-cleanup-now-keeps-versions-that-running-daemon","heading":"macOS daemon now records its version, and version cleanup keeps versions running daemons use","tier":"notice","area":"macOS","scope":"individual","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.336\/e\/macos-version-cleanup-now-keeps-versions-that-running-daemon","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.336","markdown":"### macOS daemon now records its version, and version cleanup keeps versions running daemons use\n\nOn macOS, the background daemon passes its version when it restarts after an upgrade, and old-version cleanup no longer removes versions a running daemon may need\n\n**What**\n\nClaude Code can run a daemon, a background process that keeps running without an open terminal window. On macOS, two related things changed in how it handles installed versions:\n\n- When the daemon restarts itself after an upgrade, it now passes an extra, macOS-only argument that carries the version, falling back to `VERSION` 2.1.336 if no version is available. The code paths for starting and restarting the daemon were reworked around this. Before, it restarted without the version argument.\n\n- Native version cleanup, which removes old installed copies of Claude Code, now runs `ps` (the system command that lists running programs) and reads the command lines of any running `claude daemon`, including a `--first-version=` value. It keeps versions a running daemon may need, plus the version the current program resolves to, and logs \"a running daemon may need it\" for each one it keeps. If `ps` fails or is cut short, the failure is recorded.\n\nThe cleanup is tied to the `tengu_native_version_cleanup` gate, and nothing has been read about that gate's state.\n\n**Why**\n\nCleanup should no longer delete the program files of a background daemon that is still running on macOS. Any reason beyond that, such as preventing repeated upgrade restarts, is only the finding agent's guess.\n\n- Area: macOS\n- Tier: You'll notice\n- Useful: 2\/5\n- Signal: 1\/5\n- Scope: individual\n- Heads-up: no"}