WebDriver/RemoteProtocol/Logging: Difference between revisions
< WebDriver | RemoteProtocol
Jump to navigation
Jump to search
(init) |
m (-) |
||
Line 1: | Line 1: | ||
Here are some examples of how to get verbose output with various | Here are some examples of how to get verbose output with various clients, revealing protocol-level browser activity. | ||
Environment variables to set: | Environment variables to set: | ||
Line 6: | Line 6: | ||
* If you use Playwright: <code>DEBUG=pw:*</code> ([https://github.com/microsoft/playwright/blob/master/docs/debug.md#verbose-api-logs example]) | * If you use Playwright: <code>DEBUG=pw:*</code> ([https://github.com/microsoft/playwright/blob/master/docs/debug.md#verbose-api-logs example]) | ||
However you start a [[Remote|Remote Protocol]] session, you can set a "remote.log.level" preference to "Trace" to see protocol activity. | However you start a [[Remote|Remote Protocol]] session, you can also set a "remote.log.level" preference to "Trace" to see protocol activity. | ||
Here is an [https://github.com/puppeteer/puppeteer/blob/4fdb1e3cab34310b4a1012c3024a94bc422b3b92/examples/cross-browser.js#L22 example of enabling trace-level Firefox logs] with a Puppeteer script | Here is an [https://github.com/puppeteer/puppeteer/blob/4fdb1e3cab34310b4a1012c3024a94bc422b3b92/examples/cross-browser.js#L22 example of enabling trace-level Firefox logs] with a Puppeteer script |
Revision as of 19:38, 22 July 2020
Here are some examples of how to get verbose output with various clients, revealing protocol-level browser activity.
Environment variables to set:
- If you use Puppeteer:
DEBUG=puppeteer:*
(look for verbose logging in the Puppeteer README) - If you use Playwright:
DEBUG=pw:*
(example)
However you start a Remote Protocol session, you can also set a "remote.log.level" preference to "Trace" to see protocol activity.
Here is an example of enabling trace-level Firefox logs with a Puppeteer script