mirror of
https://github.com/germondai/trawl.git
synced 2026-08-17 12:11:23 +02:00
chore(browser): suppress noExplicitAny lint in pool.ts
This commit is contained in:
@@ -6,8 +6,9 @@ import { FINGERPRINT_POOL } from "./fingerprint"
|
||||
// The pool accepts any structurally-compatible browser (Playwright OR patchright) —
|
||||
// browsers exported from one aren't structurally assignable to the other in their
|
||||
// own TypeScript types, so `any` is the pragmatic escape hatch here.
|
||||
// biome-ignore lint/suspicious/noExplicitAny: see comment above
|
||||
type Browser = any
|
||||
// biome-ignore lint/suspicious/noExplicitAny: see comment on Browser above
|
||||
// biome-ignore lint/suspicious/noExplicitAny: see comment above
|
||||
type BrowserContext = any
|
||||
|
||||
export class PoolExhaustedError extends Error {
|
||||
|
||||
@@ -128,7 +128,8 @@ export async function runTier3(
|
||||
// instead of hitting the isHardFail regex (which only matches Chromium ERR_* strings),
|
||||
// so we still need to catch the resulting about:neterror page here.
|
||||
if (isBrowserErrorPage(html)) {
|
||||
const errMsg = gotoErr instanceof Error ? gotoErr.message.split("\n")[0] : "browser network error (about:neterror)"
|
||||
const errMsg =
|
||||
gotoErr instanceof Error ? gotoErr.message.split("\n")[0] : "browser network error (about:neterror)"
|
||||
return { tier: 3, status: "error", durationMs: Date.now() - start, reason: errMsg }
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user