cmd_start fails — issue_ref_to_worktree_path creates doubled path #179
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Queue daemon runs and processes tasks correctly, but
cmd_startfails immediately with "Failed to clone repository". No worktree is created, task is marked error, daemon loops.Root Cause
The
issue_ref_to_worktree_path()function inkugetsu-worktree.shcreates an incorrect path:Since
$parent_diris already$WORKTREES_DIRwhich is~/.kugetsu-worktrees, this produces:Instead of:
The doubled path causes the git clone to fail (wrong directory), and
cmd_startexits with code 1, causing the daemon to mark the task as error.Reproduction
Observed Daemon Behavior
When daemon runs:
cmd_start git.fbrns.co/shoko/kugetsu#158 "message"cmd_startcallsworktree_exists→ uses wrong path (doubled)worktree_existsreturns false (path doesn't exist as expected)cmd_startcallscreate_worktree→ clones to wrong path → failscmd_startexits 1, daemon marks task errorFix
Remove the extra
/.kugetsu-worktrees/in the path construction.