Stale worktrees pointing to invalid HEAD should be cleaned up right away
The Cleanup
RPC attempts to remove stale worktrees after 6 hours, but a customer ran into an issue where there were worktrees pointing to a new branch (0000000000000000000000000000000000000000
) were preventing pushes from going through. We ran git worktree prune
, and it fixed the problem.
Perhaps we might want to run git worktree prune
along with the Cleanup
.