browser.driver.manage.logs.get :browser return only ERRORS

349 views
Skip to first unread message

Bernard Badó

unread,
Jan 26, 2017, 10:46:16 AM1/26/17
to Watir General
Hi,

I'm using latest version of watir(6.1) and i have problem with getting logs. I want to get logs from chrome browser using command "browser.driver.manage.logs.get :browser". When i debug my test and i try to see console logs manually. I see all kinds of logs(INFO,DEBUG,etc.). But when i call get command. All i get is just Log containing ERROR log levels. I used same code with Watir(6.0) and my log was full. Can it be possible that somehow API for logging changed? Or am i missing something? I have loggingPrefs set to log all log entries. loggingPrefs => :browser => 'ALL'

Titus Fortner

unread,
Jan 26, 2017, 2:12:27 PM1/26/17
to Watir General
It's on our list for the year to implement a Logger class for the project overall
In the meantime you should be able to get all of the debug information in STDOUT by setting $DEBUG = true

This shouldn't have anything to do with Watir per se, it would be passed along through selenium to the drivers themselves.
Is the Selenium version the same? Which browsers/drivers are you using?

Titus

Lucas Tierney

unread,
Jan 26, 2017, 2:55:22 PM1/26/17
to Watir General
I just tried this myself and it seems to be working fine. Can you share your code how you're passing the loggingPrefs into the capabilities?


On Thursday, January 26, 2017 at 9:46:16 AM UTC-6, Bernard Badó wrote:
Reply all
Reply to author
Forward
0 new messages