From e1ac2c213e8f7ed2bdc64d5826c05b65df2c28b2 Mon Sep 17 00:00:00 2001 From: grub-basket Date: Sun, 19 Jul 2026 13:55:55 -0700 Subject: [PATCH] Close stdin after writing to prevent LFS smudge hang flowStartProcess wrote to the child's stdin but never closed the write channel. DownloadLfsObjects pipes an LFS pointer into 'git lfs smudge', which reads stdin until EOF; without closeWriteChannel() the process blocks forever and the task never finishes, leaving the UI busy. Close the write channel after writing stdin. --- gitfourchette/tasks/repotask.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gitfourchette/tasks/repotask.py b/gitfourchette/tasks/repotask.py index 6f082cbf..1b44d163 100644 --- a/gitfourchette/tasks/repotask.py +++ b/gitfourchette/tasks/repotask.py @@ -503,6 +503,9 @@ def flowStartProcess(self, process: QProcess, autoFail=True, stdin: str = "") -> yield from processWrapper.coWaitStart() if stdin: process.write(stdin.encode("utf-8")) + # Close the write channel so children that read stdin to EOF + # (e.g. 'git lfs smudge') don't block forever. + process.closeWriteChannel() yield from processWrapper.coWaitFinished(autoFail) finally: self._currentProcess = None