obsidiansystems / nix-thunk

seamless management of source dependencies with nix
BSD 3-Clause "New" or "Revised" License
38 stars 10 forks source link

nix-thunk hangs when packing a very old commit #31

Open madeline-os opened 2 years ago

madeline-os commented 2 years ago

This occurred on obelisk when I tried to unpack and pack the hnix thunk there. I got around it by checking out a branch where the commit I wanted to pack was the head.

madeline-os commented 2 years ago

Specifically, this thunk on this commit: https://github.com/obsidiansystems/obelisk/blob/476bd1ce14b215d88a31a60ea1f7144710ed110f/dep/hnix/github.json

exarkun commented 1 year ago

I also encountered this when trying to re-pack an Obelisk thunk to rev 41f97410cfa2e22a4ed9e9344abcd58bbe0f3287.

ps tells me that nix-thunk has a child process /nix/store/v41a4jzfgs36srbip4gjfh2fx10m2hmj-git-2.31.1/bin/git -C impl/ rev-list --left-right master...origin/master and strace tells me that git is blocking on write(1, ">b6b219a5fdf3b3fc458723002edc3a8"..., 42). 1 is hooked up to a pipe - which I guess leads to nix-thunk so I suppose nix-thunk isn't properly managing stdio from the git process it runs and this leads to a deadlock between the two processes.