(executablePath: string)
| 235 | */ |
| 236 | let _warnedSystemFallback = false; |
| 237 | function warnSystemFallbackOnce(executablePath: string): void { |
| 238 | if (_warnedSystemFallback) return; |
| 239 | if (process.platform !== "linux") return; |
| 240 | if (isHeadlessShellBinary(executablePath)) return; |
| 241 | _warnedSystemFallback = true; |
| 242 | console.warn( |
| 243 | `[hyperframes] Using system Chrome at ${executablePath}; HeadlessExperimental.beginFrame is unavailable in regular Chrome builds, so the perf-optimized capture path falls back to screenshot mode. Install chrome-headless-shell for the optimized path:\n npx @puppeteer/browsers install chrome-headless-shell\n(Or set HYPERFRAMES_BROWSER_PATH to point at an existing chrome-headless-shell binary.)`, |
| 244 | ); |
| 245 | } |
| 246 | |
| 247 | /** Test-only: reset the one-shot warn latch. */ |
| 248 | export function _resetSystemFallbackWarnForTests(): void { |
no test coverage detected