puppeteer
puppeteer copied to clipboard
[Bug]: `puppeteer.limits` throws an error when used inside a durable object
Minimal, reproducible example
Steps to reproduce:
- Set up the browser rendering example from here.
- Add this line inside the durable object's
fetch
method:
let limits = await puppeteer.limits(this.env.BROWSER);
- Deploy the worker and trigger it using an HTTP request.
- Observe that you get this error:
TypeError: endpoint.fetch is not a function at PuppeteerWorkers.limits
The limits
method works as expected when used within a worker. However, when inside a durable object, it fails and throws an error.
Error string
TypeError : endpoint.fetch is not a function at PuppeteerWorkers.limits
Bug behavior
- [ ] Flaky
Background
No response
Expectation
I am expecting the limits
function to run and tell me the current browser rendering limits on my account so that I can wait if all my limits are used up before connecting to a browser in my durable object.
Reality
It throws an error when calling the limits
function inside a durable object.
Puppeteer configuration file (if used)
No response
Puppeteer version
0.0.12
Node version
20.11.1
Package manager
npm
Package manager version
9.8.1
Operating system
macOS