refactor(tools): remove remaining arbitrary workflow caps

This commit is contained in:
morluto
2026-09-29 17:00:06 +08:00
parent 4ad937c6ca
commit ecf3ed8bdb
43 changed files with 230 additions and 393 deletions
+2 -5
View File
@@ -39,7 +39,7 @@ export class BrowserStartupError extends Error {
}
}
/** Owned child process and bounded startup policy for Chrome CDP discovery. */
/** Owned child process and startup policy for Chrome CDP discovery. */
export interface BrowserStartupOptions {
readonly child: ChildProcess;
readonly executable: string;
@@ -129,7 +129,7 @@ const startupError = (
elapsedMs: Math.max(0, Math.round(performance.now() - startedAt)),
exitCode: options.child.exitCode,
signalCode: options.child.signalCode,
stderr: boundedStderr(options.stderr()),
stderr: options.stderr(),
},
state.failure === "spawn-error" ? { cause: state.cause } : undefined,
);
@@ -146,9 +146,6 @@ const readDevtoolsPort = async (path: string): Promise<number | null> => {
}
};
const boundedStderr = (stderr: string): string =>
stderr.length <= 65_536 ? stderr : stderr.slice(-65_536);
const delay = (milliseconds: number): Promise<void> =>
new Promise((resolve) => setTimeout(resolve, milliseconds));