qaf
qaf copied to clipboard
QAF can't run with Selenium 4.3.0
Starting from Selenium 4.3.0 some of the classes that QAF uses have been moved to a new package in selenium, that causes the compilation to fail since it no longer can find the required classes
Here is the QAF class using a class that is no longer located in that package
Selenium 4.2.2 https://github.com/SeleniumHQ/selenium/tree/selenium-4.2.2-java/java/src/org/openqa/selenium/interactions
From selenium 4.2.2 to Selenium 4.3.0 this classes are moved into a new package
Selenium 4.3.0 https://github.com/SeleniumHQ/selenium/tree/selenium-4.3.0/java/src/org/openqa/selenium/interactions https://github.com/SeleniumHQ/selenium/tree/selenium-4.3.0/java/src/org/openqa/selenium/remote/server/handler/interactions
QAF Version
QAF 3.1.0
Steps To Reproduce
1. Update POM file to use Selenium 4.3.0
2. Run mvn install
Expected behavior
mvn would run and tests start running
Actual behavior
maven fails indicating that the class org.openqa.selenium.interactions.HasInputDevices can't be found
Is the issue reproducible on runner?
- [ ] QAS
- [x] Maven
- [ ] Gradle
- [ ] Ant
- [ ] Eclipse
Test case sample

Thanks for reporting. We will take a look on impact and possible solution in upcoming release. Meanwhile you can continue using previous client library version targeting on latest selenium server using remote driver.
@cjayswal in our org we are also facing the same issue, only thing is that we are stuck at the moment.
- due to new edge browser version which only supported after selenium 4.8 and after.
- If we upgrade the selenium to 4.8 then we find the issue mentioned in this ticket that the class org.openqa.selenium.interactions.HasInputDevices has been removed.
So due to these two things we are not able to go further with the latest edge browser since there is compilation issue from QAF side.
I would request to please look into this or provide any workaround in this case.
@cjayswal : We are facing multiple issues as well . Can you help address the core libraries
We will have QAF 4 with minimum selenium version 4.3. Meanwhile you should try using remote driver pointing to local selenium server 4.x
We will have QAF 4 with minimum selenium version 4.3. Meanwhile you should try using remote driver pointing to local selenium server 4.x
- What is the expected release for QAF4 ?
- We are already overriding selenium which by defuult provided by QAF which is quite old. as we are currently using 4.1+ but the problem arises when we have to use 4.8+ to have latest edge support, but QAF can't go above 4.2 due to compilation issue caused by removed interfaces.
@sopansh Regarding using selenium 4.8+ with QAF 3.x, You can continue using selenium 4.1+ in your project and target to run on selenium server 4.8+. For that you need to use remote driver. Here are the steps:
-
Configure your project to use remote driver, for example:
#[selenium] remote.server=localhost remote.port=4444 driver.name=chromeRemoteDriver
-
Download and run selenium server as standalone or grid.
java -jar selenium-server-4.8.3.jar standalone --port 4444
-
Run your tests
In example above selenium server assumed to run on local machine.
Hello Chirag,
Thank you. With QAF 4.0 can we also make necessary changes around the driver Management ? As you are aware starting 4.6.0 , selenium has inbuilt driver manager. What can be done :
- Remove Webdriver Manager related code from UiDriverFactory.class
- Make necessary changes to allow use of latest selenium dependencies.
- For any customized driver initiation , listeners can be used.
Regards Saifuddin Raj
On Thu, Apr 13, 2023 at 4:51 AM Chirag Jayswal @.***> wrote:
Regarding using using selenium 4.8+, You can continue using selenium 4.1+ in your project and target to run on selenium server 4.8+. For that you need to use remote driver. Here are the steps:
Configure your project to use remote driver, for example:
#[selenium] remote.server=localhost remote.port=4444 driver.name=chromeRemoteDriver
Download https://www.selenium.dev/downloads/ and run selenium server as standalone or grid.
java -jar selenium-server-4.8.3.jar standalone --port 4444
Run your tests
In example above selenium server assumed to run on local machine.
— Reply to this email directly, view it on GitHub https://github.com/qmetry/qaf/issues/425#issuecomment-1505836011, or unsubscribe https://github.com/notifications/unsubscribe-auth/AILXHZZZJWP5LYOX6VTPJGLXA4BTZANCNFSM565TZ2YQ . You are receiving this because you commented.Message ID: @.***>
@cjayswal : Thank you very much. As part of which release version can we try this out ?
QAF 4.0.0-SNAPSHOT is available in snapshot repository to try/test. You can refer to the commit for further details. With this update qaf-support-mobile is also updated with appium minimum version to 8.
Repo:
<repository>
<id>oss.sonatype.org-snapshot</id>
<url>http://oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
Hi @cjayswal, CC: @SaifuddinR
Thanks for sharing the fix in QAF 4.0.0-SNAPSHOT we tried it out with few basic cases and it is working fine for us. Version: 1.8.0_333 Selenium Version: 4.8.2
Though, we still need to do a detail investigation which we will do by early next week.
We will keep you updated on our testing results.
Regards, Shariq
Hi @cjayswal, CC: @SaifuddinR,
We did further investigation and found some issue.
We are trying to execute testcases in Docan Browser which works for specific Chrome driver version “75.0.3770.140”. We tried below options [with no ChromeOptions and no DesiredCapabilities]. But, it is not working.
- We tried initializing the chrome driver as below :
WebDriverManager.globalConfig()
.setAvoidBrowserDetection(true)
.setChromeDriverVersion("75.0.3770.140");
But it is initializing to the latest chrome driver version and not “75.0.3770.140”. The same is working fine in QAF 3.1.0.
- We also tried to initialize the by providing chromedriver executable path for chromedriver version “75.0.3770.140". But, we are facing NoSuchMethodException.
Error log:
Starting ChromeDriver 75.0.3770.140 (2d9f97485c7b07dc18a74666574f19176731995c-refs/branch-heads/3770@{#1155}) on port 2939
Only local connections are allowed.
Please protect ports used by ChromeDriver and related test frameworks to prevent access by malicious code.
INFO - Unable to create driver instance in 3rd attempt with retry timeout of 60 seconds. You can check/set value of 'driver.init.retry.timeout' appropriately to set retry timeout on driver initialization failure.Unable to Create Driver Instance for chromedocan: java.lang.NoSuchMethodException: org.openqa.selenium.chrome.ChromeDriver.<init>(java.net.URL, org.openqa.selenium.Capabilities)
Build info: version: '4.8.2', revision: '826dbfc730'
System info: os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '1.8.0_333'
Driver info: driver.version: unknown
Can you please check and fix it before deploying these change?