Comments (18)
Please try 2.29-SNAPSHOT as the snapshot is compiled against 3.7.1.
And report your results.
from htmlunit-driver.
same problem.
tested on both arm and x86 servers
do i have to set Xvfb because it's headless?
from htmlunit-driver.
also, in idea i have : canno't resolve symbol htmlunit for :
import org.openqa.selenium.htmlunit.HtmlUnitDriver;
from htmlunit-driver.
Looks like a classpath problem. Your are sure the selenium stuff is in your clsspath?
from htmlunit-driver.
maven dependencies looks ok. See screenshot:
from htmlunit-driver.
ah the screenshot shows that html-driver is missing. i replaced the 2.29-SNAPSHOT
by 2.28
in the following:
<dependency> <groupId>org.seleniumhq.selenium</groupId> <artifactId>htmlunit-driver</artifactId> <version>2.28</version> </dependency>
And now the dependency is added and everything is working as expected.
Thanks for the help @rbri
from htmlunit-driver.
Ok great. You are right, the current html-unit driver snapshot unses the htmlunit release. I can understand that this is confusing. Sorry.
I think there is no need for defining the HtmlUnit dependency in your pom because this is already referenced from the html-unit driver package.
from htmlunit-driver.
when i comment the htmlUnit dependency, i see these 3 dependencies added:
- htmlunit: 2.21 - htmlunit-core-js: 2.17 - neko-htmlunit: 2.21
Quite old..
Whereas with the dependency defined, i have:
- htmlunit: 2.29-SNAPSHOT - htmlunit-core-js: 2.28 - neko-htmlunit: 2.28
from htmlunit-driver.
For archiving purpose, the problem is that old selenium dependencies were in the classpath, the fix is to define all selenium dependecies / HtmlUnit to avoid old transitive ones.
Relevant part of the pom which is working now is:
<dependency> <groupId>net.sourceforge.htmlunit</groupId> <artifactId>htmlunit</artifactId> <version>2.28</version> </dependency> <dependency> <groupId>org.seleniumhq.selenium</groupId> <artifactId>htmlunit-driver</artifactId> <version>2.28</version> </dependency> <dependency> <groupId>org.seleniumhq.selenium</groupId> <artifactId>selenium-api</artifactId> <version>3.7.1</version> </dependency> <dependency> <groupId>org.seleniumhq.selenium</groupId> <artifactId>selenium-support</artifactId> <version>3.7.1</version> </dependency> <dependency> <groupId>org.seleniumhq.selenium</groupId> <artifactId>selenium-remote-driver</artifactId> <version>3.7.1</version> </dependency> <dependency> <groupId>org.seleniumhq.selenium</groupId> <artifactId>selenium-java</artifactId> <version>3.7.1</version> </dependency> <dependency> <groupId>org.seleniumhq.selenium</groupId> <artifactId>selenium-chrome-driver</artifactId> <version>3.7.1</version> </dependency>
from htmlunit-driver.
when i comment the htmlUnit dependency, i see these 3 dependencies added:
- htmlunit: 2.21
- htmlunit-core-js: 2.17
- neko-htmlunit: 2.21>
Strange; the pom from htmlunit-driver 2.29-SNAPSHOT points to
- htmlunit 2.28
and htmlunit 2.28 refers - htmlunit-core-js 2.28
- neko-htmlunit 2.28
- ....
Can you pleas try to figure out if some other part of your pom point to this outdated htmlunit stuff.
from htmlunit-driver.
Here is the relevant part of : mvn dependency:tree -Dverbose
output
[INFO] +- org.seleniumhq.selenium:htmlunit-driver:jar:2.28:compile [INFO] | +- (org.seleniumhq.selenium:selenium-api:jar:2.53.1:compile - version managed from 3.7.0; omitted for conflict with 3.7.1) [INFO] | +- (org.seleniumhq.selenium:selenium-support:jar:2.53.1:compile - version managed from 3.7.0; omitted for conflict with 3.7.1) [INFO] | \- net.sourceforge.htmlunit:htmlunit:jar:2.21:compile (version managed from 2.28) [INFO] | +- xalan:xalan:jar:2.7.2:compile [INFO] | | \- xalan:serializer:jar:2.7.2:compile [INFO] | +- org.apache.commons:commons-lang3:jar:3.4:compile [INFO] | +- (org.apache.httpcomponents:httpclient:jar:4.5.3:compile - version managed from 4.5.1; omitted for duplicate) [INFO] | +- org.apache.httpcomponents:httpmime:jar:4.5.3:compile (version managed from 4.5.2) [INFO] | | \- (org.apache.httpcomponents:httpclient:jar:4.5.3:compile - version managed from 4.5.2; omitted for duplicate) [INFO] | +- net.sourceforge.htmlunit:htmlunit-core-js:jar:2.17:compile [INFO] | +- net.sourceforge.htmlunit:neko-htmlunit:jar:2.21:compile
maybe you should update update htmlunit-driver pom.xml to use latest selenium driver version:
from: <selenium.version>3.7.0</selenium.version> to: <selenium.version>3.7.1</selenium.version>
from htmlunit-driver.
maybe you should update update htmlunit-driver pom.xml to use latest selenium driver version:
That is already done and the reason why i have suggested to use htmlunit-driver:2.29-SNAPSHOT (in my first comment for this).
Can you please verify that the snapshot produces the correct dependencies for you.
from htmlunit-driver.
[INFO] +- org.seleniumhq.selenium:htmlunit-driver:jar:2.29-SNAPSHOT:compile [INFO] | +- (org.seleniumhq.selenium:selenium-api:jar:2.53.1:compile - version managed from 3.7.1; omitted for conflict with 3.7.1) [INFO] | +- (org.seleniumhq.selenium:selenium-support:jar:2.53.1:compile - version managed from 3.7.1; omitted for conflict with 3.7.1) [INFO] | \- net.sourceforge.htmlunit:htmlunit:jar:2.21:compile (version managed from 2.28)
I don't understand the: version managed from 3.7.1; omitted for conflict with 3.7.1)
from htmlunit-driver.
Can you please send me you whole pom to my private mail.
from htmlunit-driver.
how to find your private email?
from htmlunit-driver.
If you need support you have to solve that :-)
Have a look at the developer list on the HtmlUnit web site - Project Information - Team;
or you can have a look at the Imprint of the Wetator homepage.
from htmlunit-driver.
from htmlunit-driver.
Ok, took a bit longer to understand....
Your pom includes the spring boot as parent. And sadly this points to the outdated HtmlUnit 2.21.
from htmlunit-driver.
Related Issues (20)
- Driver not switching tabs and windows HOT 3
- NoSuchMethodError after quitting or closing driver and then re-calling it? HOT 6
- Angular support for htmlunitdriver ? HOT 1
- Breaking API changes in 4.8.1 HOT 9
- getDomProperty("value") does return "null" whereas getAttribute("value") returns a value HOT 9
- Selenium driver HOT 1
- Test HOT 1
- To ignore - Error during JavaScript execution HOT 3
- How to setting proxy authorization with username/passwd in ubuntu-server 18.04 env HOT 8
- org.htmlunit.ScriptException: SyntaxError: Empty JSON string HOT 9
- HtmlUnitDriver needs to provide WebDriverInfo and DriverService service providers for Selenium 4 Grid HOT 4
- Searching with RelativeLocator does not work HOT 3
- Threading problem when using multiple frames
- Implement HasAuthentication to be able to use authentication HOT 1
- elem.getAttribute("src") should return an empty string if no src attribute is present
- elem.getAttribute("xxx") should return null if no 'xxx' attribute is present
- XPath Not Working Via document.evaluate HOT 4
- Rhino not compiling any JavaScript when ScriptException encountered HOT 7
- Runasync causing deadlock?
- Fetching innerHTML HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from htmlunit-driver.