hm you could create multiple browser contexts per browser I believe
hm you could create multiple browser contexts per browser I believe

failed: Code generation from strings disallowed for this context whenever an xpath selector is used on @Cloudflare/puppeteer. I understand it's a security measure to restrict the use of createFunction in the worker, but it's necessary for xpaths to work in puppeteer. does anyone have a clue how to work around this?page.waitForXPath(xPathSelector, { visible: true })
I need to perform an arbitrary number of browser rendering requests at once.Maybe you can use a queue? Your queue producer will send the rendering requests and the consumer will make these requests as time permits (2 sessions per minute)...
@person).Argument of type 'Fetcher' is not assignable to parameter of type 'BrowserWorker'.
Types of property 'fetch' are incompatible.
Type '(input: RequestInfo<unknown, CfProperties<unknown>>, init?: RequestInit<CfProperties<unknown>> | undefined) => Promise<Response>' is not assignable to type '{ (input: RequestInfo | URL, init?: RequestInit | undefined): Promise<Response>; (input: RequestInfo, init?: RequestInit | undefined): Promise<...>; }'.
//env
import { Fetcher } from "@cloudflare/workers-types";
export interface env {
MYBROWSER: Fetcher
} stack: EvalError: Code generation from strings disallowed for this context
at new Function (<anonymous>)
at createFunction (file://<app-root>/.wrangler/tmp/dev-Ol4QPo/index.js:93195:9)
at interpolateFunction (file://<app-root>/.wrangler/tmp/dev-Ol4QPo/index.js:93214:10)
at get _querySelector (file://<app-root>/.wrangler/tmp/dev-Ol4QPo/index.js:93288:33)
at XPathQueryHandler.waitFor (file://<app-root>/.wrangler/tmp/dev-Ol4QPo/index.js:93374:34)
at Frame2.waitForSelector (file://<app-root>/.wrangler/tmp/dev-Ol4QPo/index.js:102047:32)
at Frame2.waitForXPath (file://<app-root>/.wrangler/tmp/dev-Ol4QPo/index.js:102075:17)
at CDPPage.waitForXPath (file://<app-root>/.wrangler/tmp/dev-Ol4QPo/index.js:100304:29)