selenium: [š Bug]: Can't display SeleniumManager logs at any level when switching from 4.12.0 to 4.12.1
What happened?
Iāve found a strange behavior about this log change switching from 4.12.0 to 4.12.1, itās like nothing is logged at any level in 4.12.1 (probably related to https://github.com/SeleniumHQ/selenium/pull/12673)
Iām using a jul-to-slf4j conversion which works perfecty until 4.12.0, but no more logs in 4.12.1
Using a āTRACEā log level which includes FINEST, FINER and FINE :
FINEST -> TRACE FINER -> DEBUG FINE -> DEBUG INFO -> INFO WARNING -> WARN SEVERE -> ERROR
logback.xml :
<logger name="org.openqa.selenium.manager" level="TRACE" />
Using selenium-java 4.12.0, I see this :
12:08:36.961 [Timer-0] INFO o.o.selenium.manager.SeleniumManager - Driver path: C:\Users\PC\.cache\selenium\chromedriver\win64\116.0.5845.96\chromedriver.exe
12:08:36.962 [Timer-0] INFO o.o.selenium.manager.SeleniumManager - Browser path: C:\Program Files\Google\Chrome\Application\chrome.exe
when upgrading to 4.12.1, I see no SeleniumManager log when I would expect to see :
12:08:36.961 [Timer-0] DEBUG o.o.selenium.manager.SeleniumManager - Driver path: C:\Users\PC\.cache\selenium\chromedriver\win64\116.0.5845.96\chromedriver.exe
12:08:36.962 [Timer-0] DEBUG o.o.selenium.manager.SeleniumManager - Browser path: C:\Program Files\Google\Chrome\Application\chrome.exe
after this change : https://github.com/SeleniumHQ/selenium/pull/12673
Switching back to 4.12.0 (with no other change) restores the logs.
How can we reproduce the issue?
To reproduce, just try to display SeleniumManager logs from a calling program having this dependency :
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-java</artifactId>
<version>4.12.0</version>
</dependency>
Then upgrade to 4.12.1 and see the logs are no more displayed.
Relevant log output
12:08:36.961 [Timer-0] INFO o.o.selenium.manager.SeleniumManager - Driver path: C:\Users\PC\.cache\selenium\chromedriver\win64\116.0.5845.96\chromedriver.exe
12:08:36.962 [Timer-0] INFO o.o.selenium.manager.SeleniumManager - Browser path: C:\Program Files\Google\Chrome\Application\chrome.exe
### Operating System
Windows 10
### Selenium version
4.12.1
### What are the browser(s) and version(s) where you see this issue?
Pb in SeleniumManager, present for all browsers and all versions
### What are the browser driver(s) and version(s) where you see this issue?
ChromeDriver 116.0.5845.96
### Are you using Selenium Grid?
no
About this issue
- Original URL
- State: closed
- Created 10 months ago
- Comments: 16 (8 by maintainers)
Oups, here is a few more precise hints/steps if u need :
java.util.logging.LogManager.getLogManager().getLogger("").setLevel(Level.FINE);right afterSLF4JBridgeHandler.install();to make all ājava.util.loggingā logs available to the ābridgeā mechanismFrom there, you can configure logs in ālogback.xmlā to be placed in src/main/resources, basic example :
P.S. : Iām not saying itās āeasierā than what you provide, but it has been the way to configure logs in java since the creation of ālog4jā 20+ years ago, and it has not changed much, so once u know how it works, u can reuse it forever, for any java project⦠š