Skip to content

Commit 7d50a39

Browse files
Update src/browser.ts
Co-authored-by: Akihiro Tamada <spring-raining@users.noreply.github.com>
1 parent 89761b8 commit 7d50a39

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

src/browser.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,11 +217,12 @@ async function launchBrowser({
217217
protocolTimeout,
218218
} satisfies LaunchOptions;
219219
Logger.debug('launchOptions %O', launchOptions);
220+
// #416: set Chromium language to English to avoid locale-dependent issues
221+
const env: NodeJS.ProcessEnv = { ...process.env, LANG: 'en.UTF-8' };
220222
// Browsers store transient data that never affects rendering (crash dumps,
221223
// profiles.ini) under HOME (chrome_paths_linux.cc, nsXREDirProvider.cpp). A
222224
// container UID with no /etc/passwd entry (e.g. `docker run --user`)
223225
// gets the unwritable HOME `/`, so the browser cannot launch (see #835).
224-
const env: NodeJS.ProcessEnv = { ...process.env, LANG: 'en.UTF-8' };
225226
if (process.platform === 'linux' && !isWritableDir(env.HOME)) {
226227
[env.HOME] = await useTmpDirectory();
227228
}

0 commit comments

Comments
 (0)