Skip to content

Commit 5954947

Browse files
fix: don't detect browsers in webpack info on Windows
On Windows, `envinfo` starts the browsers themselves to get their versions, which can hang, e.g. the `info` tests time out on Windows CI runners. Claude-Session: https://claude.ai/code/session_013FhutRFjuQemBzekJMYcqL
1 parent f37a6bc commit 5954947

1 file changed

Lines changed: 18 additions & 12 deletions

File tree

‎packages/webpack-cli/src/webpack-cli.ts‎

Lines changed: 18 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1886,18 +1886,24 @@ class WebpackCLI {
18861886
} else {
18871887
const defaultInformation: EnvinfoConfig = {
18881888
Binaries: ["Node", "Yarn", "npm", "pnpm"],
1889-
Browsers: [
1890-
"Brave Browser",
1891-
"Chrome",
1892-
"Chrome Canary",
1893-
"Edge",
1894-
"Firefox",
1895-
"Firefox Developer Edition",
1896-
"Firefox Nightly",
1897-
"Internet Explorer",
1898-
"Safari",
1899-
"Safari Technology Preview",
1900-
],
1889+
// On Windows, `envinfo` starts the browsers themselves to get their versions,
1890+
// which can hang (e.g. on CI), so they are skipped there
1891+
...(process.platform === "win32"
1892+
? {}
1893+
: {
1894+
Browsers: [
1895+
"Brave Browser",
1896+
"Chrome",
1897+
"Chrome Canary",
1898+
"Edge",
1899+
"Firefox",
1900+
"Firefox Developer Edition",
1901+
"Firefox Nightly",
1902+
"Internet Explorer",
1903+
"Safari",
1904+
"Safari Technology Preview",
1905+
],
1906+
}),
19011907
// @ts-expect-error No in types
19021908
Monorepos: ["Yarn Workspaces", "Lerna"],
19031909
System: ["OS", "CPU", "Memory"],

0 commit comments

Comments
 (0)