selenium firefox个人资料例外

时间:2012-04-19 08:57:57

标签: selenium webdriver

java.lang.NoSuchMethodError:org.apache.http.conn.scheme.Scheme。 (Ljava /郎/字符串; ILorg /阿帕奇/ HTTP /康恩/方案/ SchemeSocketFactory;)V                 在org.openqa.selenium.remote.internal.HttpClientFactory.getClientConnectionManager(HttpClientFactory.java:64)                 在org.openqa.selenium.remote.internal.HttpClientFactory。(HttpClientFactory.java:50)                 在org.openqa.selenium.remote.HttpCommandExecutor。(HttpCommandExecutor.java:111)                 在org.openqa.selenium.firefox.internal.NewProfileExtensionConnection.start(NewProfileExtensionConnection.java:78)                 在org.openqa.selenium.firefox.FirefoxDriver.startClient(FirefoxDriver.java:187)                 在org.openqa.selenium.remote.RemoteWebDriver。(RemoteWebDriver.java:93)                 在org.openqa.selenium.firefox.FirefoxDriver。(FirefoxDriver.java:142)                 在org.openqa.selenium.firefox.FirefoxDriver。(FirefoxDriver.java:88)                 在com.ensarm.crawler.web.browser.FirefoxBrowser.initialize(FirefoxBrowser.java:296)                 在com.ensarm.crawler.navigator.IpProxyNavigator.initialize(IpProxyNavigator.java:46)                 在com.ensarm.crawler.Crawler.run(Crawler.java:23)                 在java.lang.Thread.run(Thread.java:619)

  this is my ivy.xml file .
   <dependencies>
    <dependency org="antlr" name="antlr" rev="2.7.6"/>
    <dependency org="aopalliance" name="aopalliance" rev="1.0"/>
     <dependency org="bouncycastle" name="bcmail-jdk14" rev="139"/>
     <dependency org="commons-collections" name="commons-collections" rev="3.1"/>
     <dependency org="commons-dbcp" name="commons-dbcp" rev="1.4"/>
     <dependency org="commons-httpclient" name="commons-httpclient" rev="3.1"/>
               <dependency org="commons-logging" name="commons-logging" rev="1.1.1"/>
               <dependency org="commons-pool" name="commons-pool" rev="1.6"/>
               <dependency org="dom4j" name="dom4j" rev="1.6.1"/>
               <dependency org="org.hibernate" name="ejb3-persistence" rev="1.0.2.GA"/>
               <dependency org="org.apache.pdfbox" name="fontbox" rev="1.6.0"/>
               <dependency org="jtidy" name="jtidy" rev="4aug2000r7-dev"/>
               <dependency org="org.seleniumhq.selenium" name="selenium-java" rev="2.20.0"/>
                <dependency org="javax.inject" name="javax.inject" rev="1"/>
               <dependency org="javax.transaction" name="jta" rev="1.1"/>
               <dependency org="org.hibernate" name="hibernate-validator" rev="4.0.2.GA"/>
               <dependency org="org.hibernate" name="hibernate-cglib-repack" rev="2.1_3"/>
               <dependency org="org.hibernate" name="hibernate-annotations" rev="3.5.6-Final"/>
               <dependency org="org.slf4j" name="slf4j-api" rev="1.6.0"/>
               <dependency org="org.slf4j" name="slf4j-jcl" rev="1.6.0"/>
               <dependency org="org.slf4j" name="slf4j-log4j12" rev="1.6.0"/>
               <dependency org="org.slf4j" name="slf4j-simple" rev="1.6.0"/>  
               <dependency org="mysql" name="mysql-connector-java" rev="5.1.18"/>
               <dependency org="pdfbox" name="pdfbox" rev="0.7.3"/>
               <dependency org="jaxen" name="jaxen" rev="1.1.1"/>
               <dependency org="org.seleniumhq.webdriver" name="webdriver-firefox" rev="0.9.7376"/>
               <dependency org="org.seleniumhq.webdriver" name="webdriver-common" rev="0.9.7376"/>
               <dependency org="javassist" name="javassist" rev="3.4.GA"/>
               <dependency org="net.sf.hibernate4gwt" name="hibernate4gwt" rev="1.0.4"/>
               <dependency org="org.seleniumhq.selenium" name="selenium-server" rev="2.20.0"/>
                </dependencies>

  getting above exception.. dont know which jar is missing... 

1 个答案:

答案 0 :(得分:0)

这些是我使用selenium时为我下载的所有罐子maven

  • 硒 - java的2.20.0.jar
  • 硒 - 机器人驱动器-2.20.0.jar
  • 硒 - 远程驾驶员2.20.0.jar
  • CGLIB的节点p-2.1_3.jar
  • json-20080701.jar
  • guava-11.0.1.jar jsr305-1.3.9.jar
  • 硒 - 铬 - 驾驶员2.20.0.jar
  • 硒的HtmlUnit-驾驶员2.20.0.jar
  • 硒 - API-2.20.0.jar
  • htmlunit-2.9.jar xalan-2.7.1.jar
  • serializer-2.7.1.jar
  • 公地集合-3.2.1.jar
  • commons-lang-2.6.jar
  • httpmime-4.1.2.jar
  • 公地编解码器-1.4.jar
  • 的HtmlUnit核-JS-2.9.jar
  • xercesImpl-2.9.1.jar
  • XML的API-1.3.04.jar
  • nekohtml-1.9.15.jar
  • cssparser-0.9.5.jar
  • SAC-1.3.jar
  • 共享记录-1.1.1.jar
  • 的HttpClient-4.1.2.jar
  • 的HttpCore-4.1.2.jar
  • 硒 - 火狐-驾驶员2.20.0.jar
  • 公地-IO-2.0.1.jar
  • 公地EXEC-1.1.jar
  • selenium-ie-driver-2.20.0.jar
  • JNA-3.4.0.jar
  • platform-3.4.0.jar
  • 硒 - iphone-驾驶员2.20.0.jar
  • 含硒载体-2.20.0.jar

我建议你先把它们全部拿出然后逐个删除,直到找到它实际需要的为止。