Skip to content

feat(browser): add :ignore_js_errors to skip known errors with js_errors - #638

Closed
oleksii-leonov wants to merge 1 commit into
rubycdp:mainfrom
syngenta:ignore-js-errors
Closed

oleksii-leonov wants to merge 1 commit into
rubycdp:mainfrom
syngenta:ignore-js-errors

Conversation

@oleksii-leonov

Copy link
Copy Markdown

js_errors: true re-raises every uncaught JavaScript exception a page throws, with no way to leave some out. Some pages (especially in system specs) can throw exceptions that are benign ("ResizeObserver loop completed with undelivered notifications.", etc). Right now there is no mechanism to ignore them.

The new option ignore_js_errors: takes an Array of Regexp (defaults to an empty array). When js_errors is on and a matches the error message, the exception is dropped instead of raised.

`js_errors: true` re-raises every uncaught JavaScript exception a page throws, with no way to leave some out. Some pages (especially in system specs) can throw exceptions that are benign ("ResizeObserver loop completed with undelivered notifications.", etc). Right now there is no mechanism to ignore them.

The new option `ignore_js_errors:` takes an Array of Regexp (defaults to an empty array). When `js_errors` is on and a matches the error message, the exception is dropped instead of raised.
@route

route commented Sep 28, 2026

Copy link
Copy Markdown
Member

I don't think anything of this matters for Ferrum. I believe even js_errors belongs to Cuprite. So I would consider adding it to Cuprite rather than Ferrum

@route

route commented Sep 28, 2026

Copy link
Copy Markdown
Member

Mind opening on Cuprite?

@route route closed this Sep 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants