debug
debug copied to clipboard
Redirect logs to file doesnt capture time
https://github.com/microsoft/playwright uses debug module for logging. While using playwright i observed that when using DEBUG_FILE env variable to redirect these logs to file, it doesnt show time whereas when we output it to console, it shows time.
Expected
pw:api => selectors.setTestIdAttribute started +0ms pw:api => browserType.launch started +7ms
Actual
pw:api => selectors.setTestIdAttribute started pw:api => browserType.launch started
down stream issue https://github.com/microsoft/playwright/issues/27477
I noticed the same thing. You can set the env DEBUG_COLORS=yes
and get the ms
, but if you are redirecting to a text file, it will still include the colour formatting characters.
I noticed the same thing. You can set the env
DEBUG_COLORS=yes
and get thems
, but if you are redirecting to a text file, it will still include the colour formatting characters.
I tried it but i still didnt get time in log file.