-
Notifications
You must be signed in to change notification settings - Fork 9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Console event is not triggered by console errors #1512
Comments
This works for me:
I think the section on the console event doesn't make it super clear
that you have to listen to different events, e.g. pageerror, to capture the various messages the console shows. Cheers, |
That did the trick @mwhitaker, thanks! |
page.on('console', msg => console.log('PAGE LOG:', msg.text)); Should be page.on('console', msg => console.log('PAGE LOG:', msg.text())); |
Any one having issues with this its missing the function call |
@mwhitaker @joshuaaguilar20 @softaria-roman Any suggestions how can we print stack trace for browser errors? error.stack did not work for me. |
Steps to reproduce
Tell us about your environment:
What steps will reproduce the problem?
Please include code that reproduces the issue.
What is the expected result?
I expect the console event to be triggered for all 4 of the console items shown in the screenshot below:
What happens instead?
It only gets triggered by the first console item which was from a console.log message.
The text was updated successfully, but these errors were encountered: