#9959·npm

在 Windows 上,当 stdin 是管道时, npx -y 会卡死(与 MCP/LSP stdio IPC 造成死锁)

作者: Gaoang-623创建于 2026年9月9日更新于 2026年9月15日
标签Priority 2

Summary

npx -y <package> hangs indefinitely on Windows when stdin is redirected to a pipe, despite the -y flag being present. This occurs because npx still attempts to read from stdin for interactive prompts, causing a deadlock when the parent process has already taken over stdin for IPC communication.