Steerpike
Steerpike

Reputation: 1863

Maven fails to pull down latest Selenium Java jar

I'm trying to simply add the latest Selenium 2.44.0 to my project in IntelliJ, for some reason it's happy with 2.42.0 but 2.44.0 errors with

"Dependency '''org.seleniumhq.selenium:selenium-java:2.44.0''' not found"

Any ideas what's going on? My POM in its entirety:-

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>com.test.testproj</groupId>
<artifactId>twitterati</artifactId>
<version>1.0-SNAPSHOT</version>
<properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>

<dependencies>

    <dependency>
        <groupId>org.hamcrest</groupId>
        <artifactId>hamcrest-all</artifactId>
        <version>1.3
        </version>
    </dependency>

    <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>4.11</version>
    </dependency>


    <dependency>
        <groupId>org.seleniumhq.selenium</groupId>
        <artifactId>selenium-java</artifactId>
        <version>2.44.0</version>
    </dependency>


</dependencies>

Upvotes: 2

Views: 14241

Answers (3)

Suresh Halubai
Suresh Halubai

Reputation: 61

Right click on the project, Select maven-->Reload the project this shall reload and download the dependency you have problem with.

Upvotes: 5

Manfred Moser
Manfred Moser

Reputation: 29912

First try running on the command line by forcing an update.

mvn clean install -U

If that fails, try the same after removing your local repository and check the contents of your ~/.m2/settings.xml file and let us know if there is anything in there.

And then if that still fails .. see if you can ping the Maven repository. (repo1.maven.apache.org).

Upvotes: 8

djangofan
djangofan

Reputation: 29689

I would make sure you are not passing the offline option to Maven by accident ( -o ) and also make sure nothing exists in your settings.xml file that might reroute your repository location.

Upvotes: 2

Related Questions