{"version":"2.1.318","anchor":"version-cleanup-uses-lock-directory-scan-pid-lock-records-p","canonical_anchor":"version-cleanup-uses-lock-directory-scan-pid-lock-records-p","heading":"Old-version cleanup now skips itself when it cannot check which versions are in use","tier":"notice","area":"Auto-Updater","scope":"individual","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.318\/e\/version-cleanup-uses-lock-directory-scan-pid-lock-records-p","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.318","markdown":"### Old-version cleanup now skips itself when it cannot check which versions are in use\n\nClaude Code checks its lock folder before deleting old installed versions and skips cleanup entirely if it cannot read it\n\n**Unclear.** It is not clear on which operating systems the per-process lock is written.\n\n**What**\n\nClaude Code deletes old versions of itself from your computer from time to time. Before it does, it now reads the folder of lock files. A lock file is a small marker a running copy of Claude Code leaves to say a version is in use. If that folder cannot be read, Claude Code skips the cleanup and logs \"Skipping version cleanup: could not read the locks, so lock protection is unavailable\". Previously each version was checked one at a time.\n\nEach running copy of Claude Code can also now write a lock tied to its own process ID, the number your operating system gives a running program.\n\n**Why**\n\nThis stops Claude Code from deleting a version that another open copy of Claude Code is still running.\n\n- Area: Auto-Updater\n- Tier: You'll notice\n- Useful: 1\/5\n- Signal: 1\/5\n- Scope: individual\n- Heads-up: no"}