我正在沙箱(linux沙箱)環境中開發。執行 git push 時,測驗系統拋出此錯誤:
git.exc.GitCommandError: Cmd('git') failed due to: exit code(128)
cmdline: git worktree add /var/lib/snapshooter/instances/xxxxxxxxxxxxx
stdout: 'Preparing worktree (detached HEAD xxxxxx)'
stderr: 'fatal: '/var/lib/snapshooter/instances/xxxxxxxxxxxxx' is a missing but already registered worktree;
use 'add -f' to override, or 'prune' or 'remove' to clear'
我已經運行了 git prune 、git gc 并重新生成了 SSH 密鑰,但我不知道還能做什么。
uj5u.com熱心網友回復:
這是git worktree。
測驗系統創建一個額外的作業樹來處理您正在推送的提交。它遇到了一個錯誤。作業樹/var/lib/snapshooter/instances/xxxxxxxxxxxxx是在上一次推送期間創建的。但它沒有正確修剪。要修復錯誤,請讓測驗系統管理員git worktree prune在主作業樹中運行。主作業樹位于測驗系統機器上。
轉載請註明出處,本文鏈接:https://www.uj5u.com/gongcheng/431868.html
