diff --git a/changes/11564.fix.md b/changes/11564.fix.md new file mode 100644 index 00000000000..f528deff836 --- /dev/null +++ b/changes/11564.fix.md @@ -0,0 +1 @@ +Fix the installer hanging on the WSL/LiveCD environment warning when run with `--headless` because the "Press Enter to continue" prompt could not receive keystrokes; in headless mode it now auto-proceeds after printing the warning. diff --git a/src/ai/backend/install/widgets.py b/src/ai/backend/install/widgets.py index 65bd5662cd3..1dae0de379d 100644 --- a/src/ai/backend/install/widgets.py +++ b/src/ai/backend/install/widgets.py @@ -97,7 +97,12 @@ async def wait_continue(self) -> None: """ Block until the user concludes the dialog. If the user cancels, the result will be None. + In headless mode there is no terminal-attached UI to receive the Enter + keypress, so we auto-proceed instead of blocking forever. """ + if self.app.is_headless: + self.write(Text.from_markup("\n[dim](headless mode: auto-continuing)[/]\n")) + return self.write(Text.from_markup("\nPress [bold]Enter[/] to continue...\n")) self._continue.clear() await self._continue.wait()