{"version":"2.1.327","anchor":"stale-git-lock-files-removed-before-byoc-repo-setup","canonical_anchor":"stale-git-lock-files-removed-before-byoc-repo-setup","heading":"Leftover git lock files are cleared before setting up a cloud session's repository","tier":"notice","area":"Cloud Sessions","scope":"individual","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.327\/e\/stale-git-lock-files-removed-before-byoc-repo-setup","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.327","markdown":"### Leftover git lock files are cleared before setting up a cloud session's repository\n\nWhen setting up a repository for a remote session, Claude Code can now delete git lock files left behind by an interrupted git\n\n**Unclear.** Which kinds of session turn this cleanup on is not stated.\n\n**What**\n\nWhen git is cut short, it can leave lock files (files ending in `.lock`) behind, and later git commands then refuse to run. When the option is turned on, Claude Code now scans the repository's `.git` folder, including its refs, logs, worktrees and reftable folders, before setting up the repository, and deletes any such leftover lock files. Each removal is logged with the message \"Removed stale ... left by a git that was cut short\".\n\n**Why**\n\nCloud or remote sessions that used to fail because of leftover lock files can now recover on their own.\n\n- Area: Cloud Sessions\n- Tier: You'll notice\n- Useful: 2\/5\n- Signal: 2\/5\n- Scope: individual\n- Heads-up: no"}