You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(6) |
Jul
(17) |
Aug
(18) |
Sep
(22) |
Oct
(16) |
Nov
(6) |
Dec
(11) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(11) |
Feb
(10) |
Mar
(34) |
Apr
(26) |
May
(6) |
Jun
(22) |
Jul
(14) |
Aug
(4) |
Sep
(47) |
Oct
(69) |
Nov
(23) |
Dec
(21) |
2005 |
Jan
(53) |
Feb
(33) |
Mar
(92) |
Apr
(65) |
May
(63) |
Jun
(57) |
Jul
(43) |
Aug
(132) |
Sep
(61) |
Oct
(75) |
Nov
(60) |
Dec
(130) |
2006 |
Jan
(74) |
Feb
(87) |
Mar
(101) |
Apr
(58) |
May
(54) |
Jun
(42) |
Jul
(31) |
Aug
(67) |
Sep
(61) |
Oct
(71) |
Nov
(28) |
Dec
(58) |
2007 |
Jan
(53) |
Feb
(50) |
Mar
(96) |
Apr
(66) |
May
(55) |
Jun
(130) |
Jul
(99) |
Aug
(115) |
Sep
(37) |
Oct
(78) |
Nov
(24) |
Dec
(70) |
2008 |
Jan
(94) |
Feb
(85) |
Mar
(197) |
Apr
(274) |
May
(119) |
Jun
(143) |
Jul
(193) |
Aug
(99) |
Sep
(160) |
Oct
(120) |
Nov
(178) |
Dec
(109) |
2009 |
Jan
(238) |
Feb
(169) |
Mar
(115) |
Apr
(109) |
May
(131) |
Jun
(167) |
Jul
(144) |
Aug
(193) |
Sep
(155) |
Oct
(154) |
Nov
(97) |
Dec
(127) |
2010 |
Jan
(108) |
Feb
(127) |
Mar
(176) |
Apr
(113) |
May
(130) |
Jun
(200) |
Jul
(115) |
Aug
(80) |
Sep
(92) |
Oct
(101) |
Nov
(124) |
Dec
(53) |
2011 |
Jan
(67) |
Feb
(144) |
Mar
(88) |
Apr
(60) |
May
(89) |
Jun
(54) |
Jul
(68) |
Aug
(81) |
Sep
(48) |
Oct
(40) |
Nov
(10) |
Dec
(20) |
2012 |
Jan
(21) |
Feb
(28) |
Mar
(17) |
Apr
(35) |
May
(41) |
Jun
(44) |
Jul
(68) |
Aug
(67) |
Sep
(89) |
Oct
(58) |
Nov
(47) |
Dec
(56) |
2013 |
Jan
(49) |
Feb
(28) |
Mar
(46) |
Apr
(31) |
May
(28) |
Jun
(37) |
Jul
(34) |
Aug
(52) |
Sep
(42) |
Oct
(108) |
Nov
(59) |
Dec
(56) |
2014 |
Jan
(41) |
Feb
(72) |
Mar
(46) |
Apr
(21) |
May
(19) |
Jun
(17) |
Jul
(15) |
Aug
(40) |
Sep
(11) |
Oct
(3) |
Nov
(5) |
Dec
(31) |
2015 |
Jan
(11) |
Feb
(12) |
Mar
(19) |
Apr
(19) |
May
(38) |
Jun
(54) |
Jul
(14) |
Aug
(42) |
Sep
(14) |
Oct
(16) |
Nov
(26) |
Dec
(14) |
2016 |
Jan
(3) |
Feb
(1) |
Mar
(24) |
Apr
(5) |
May
(15) |
Jun
(14) |
Jul
(33) |
Aug
(19) |
Sep
(8) |
Oct
(10) |
Nov
|
Dec
(2) |
2017 |
Jan
(16) |
Feb
(12) |
Mar
(23) |
Apr
(8) |
May
(11) |
Jun
(20) |
Jul
(21) |
Aug
(20) |
Sep
|
Oct
(6) |
Nov
(9) |
Dec
(2) |
2018 |
Jan
(7) |
Feb
(5) |
Mar
(6) |
Apr
(5) |
May
(1) |
Jun
(2) |
Jul
(2) |
Aug
|
Sep
(4) |
Oct
(3) |
Nov
|
Dec
(4) |
2019 |
Jan
(2) |
Feb
(2) |
Mar
(3) |
Apr
(4) |
May
|
Jun
(4) |
Jul
(9) |
Aug
(2) |
Sep
|
Oct
(4) |
Nov
(1) |
Dec
(7) |
2020 |
Jan
(2) |
Feb
(6) |
Mar
(9) |
Apr
(1) |
May
(1) |
Jun
(15) |
Jul
(1) |
Aug
(1) |
Sep
(2) |
Oct
(6) |
Nov
(3) |
Dec
(5) |
2021 |
Jan
(3) |
Feb
(1) |
Mar
(2) |
Apr
(1) |
May
|
Jun
(1) |
Jul
(1) |
Aug
(3) |
Sep
(1) |
Oct
|
Nov
(1) |
Dec
|
2022 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(2) |
Jun
(1) |
Jul
(4) |
Aug
|
Sep
|
Oct
|
Nov
(1) |
Dec
(6) |
2025 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: David M. G. <mic...@gm...> - 2013-11-11 08:19:21
|
On Mon, Nov 11, 2013 at 9:59 AM, David Michael Gang <mic...@gm...>wrote: > Hi, > > I tried with the latest snapshot from > http://build.canoo.com/htmlunit/artifacts/ > > public static void main(String[] args) throws > FailingHttpStatusCodeException, MalformedURLException, IOException { > WebClient w = new WebClient(); > HtmlPage p = w.getPage(" > https://www.sciencedirect.com/science/book/9780121346454"); > System.out.println(p.asText()); > } > > > and get the error messages (shortened exception stack): > 11/11/2013 09:55:18 > com.gargoylesoftware.htmlunit.IncorrectnessListenerImpl notify > WARNING: Obsolete content type encountered: 'text/javascript'. > 11/11/2013 09:55:18 > com.gargoylesoftware.htmlunit.IncorrectnessListenerImpl notify > WARNING: Obsolete content type encountered: 'application/x-javascript'. > 11/11/2013 09:55:18 > com.gargoylesoftware.htmlunit.javascript.StrictErrorReporter runtimeError > SEVERE: runtimeError: message=[The data necessary to complete this > operation is not yet available.] sourceName=[ > https://cdn.optimizely.com/js/204774041.js] line=[31] lineSource=[null] > lineOffset=[0] > > null [0:0] Error in expression. (Invalid token "<EOF>". Was expecting one > of: <NUMBER>, "inherit", <IDENT>, <STRING>, <PLUS>, <HASH>, <EMS>, <EXS>, > <LENGTH_PX>, <LENGTH_CM>, <LENGTH_MM>, <LENGTH_IN>, <LENGTH_PT>, > <LENGTH_PC>, <ANGLE_DEG>, <ANGLE_RAD>, <ANGLE_GRAD>, <TIME_MS>, <TIME_S>, > <FREQ_HZ>, <FREQ_KHZ>, <PERCENTAGE>, <DIMENSION>, <URI>, <FUNCTION>, "-".) > 11/11/2013 09:55:21 > com.gargoylesoftware.htmlunit.javascript.StrictErrorReporter runtimeError > SEVERE: runtimeError: message=[The data necessary to complete this > operation is not yet available.] sourceName=[ > http://cdn.els-cdn.com/sd/js/sdX_133aR4.js] line=[2] lineSource=[null] > lineOffset=[0] > 11/11/2013 09:55:21 com.gargoylesoftware.htmlunit.DefaultCssErrorHandler > error > WARNING: CSS error: 'http://cdn.els-cdn.com/sd/css/css_gen_v01_133aR4.css' > [945:46] Error in style rule. (Invalid token "!important". Was expecting > one of: <EOF>, <S>, <IDENT>, "}", ";".) > ... > > WARNING: Automation server can't create object for > 'ShockwaveFlash.ShockwaveFlash'. > 11/11/2013 09:55:22 > com.gargoylesoftware.htmlunit.javascript.StrictErrorReporter runtimeError > SEVERE: runtimeError: message=[Automation server can't create object for > 'ShockwaveFlash.ShockwaveFlash'.] sourceName=[ > http://cdn.els-cdn.com/sd/js/sdX_133aR4.js] line=[24] lineSource=[null] > lineOffset=[0] > 11/11/2013 09:55:23 com.gargoylesoftware.htmlunit.html.BaseFrameElement > loadInnerPageIfPossible > SEVERE: IOException when getting content for iframe: url=[ > https://acw.scopus.com/SSOCore/update?acw=61d5d88a1164241502b86549eb96594e1fe0521%7C%24%7CJaYnPDv2odsjkuRTDTxw4aRRMXBZiJ8Mr3nxjU06KnmV2KWzVYCF9l%2FJd6PrZZXDpLLlYpMRbbWjmt81zQFCVK2W%2F%2B9o4%2Fzy > ] > javax.net.ssl.SSLHandshakeException: > sun.security.validator.ValidatorException: PKIX path building failed: > sun.security.provider.certpath.SunCertPathBuilderException: unable to find > valid certification path to requested target > at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:174) > at > com.sun.net.ssl.internal.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1747) > ... > at > org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:72) > at > com.gargoylesoftware.htmlunit.HttpWebConnection.getResponse(HttpWebConnection.java:167) > at > com.gargoylesoftware.htmlunit.WebClient.loadWebResponseFromWebConnection(WebClient.java:1281) > at > com.gargoylesoftware.htmlunit.WebClient.loadWebResponse(WebClient.java:1198) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:307) > at > com.gargoylesoftware.htmlunit.html.BaseFrameElement.loadInnerPageIfPossible(BaseFrameElement.java:174) > at > com.gargoylesoftware.htmlunit.html.BaseFrameElement.loadInnerPage(BaseFrameElement.java:112) > at > com.gargoylesoftware.htmlunit.html.HtmlPage.loadFrames(HtmlPage.java:1880) > at > com.gargoylesoftware.htmlunit.html.HtmlPage.initialize(HtmlPage.java:232) > at > com.gargoylesoftware.htmlunit.WebClient.loadWebResponseInto(WebClient.java:444) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:311) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:376) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:361) > at test.Test.main(Test.java:15) > Caused by: sun.security.validator.ValidatorException: PKIX path building > failed: sun.security.provider.certpath.SunCertPathBuilderException: unable > to find valid certification path to requested target > at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:323) > at > sun.security.validator.PKIXValidator.engineValidate(PKIXValidator.java:217) > at sun.security.validator.Validator.validate(Validator.java:218) > at > com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.validate(X509TrustManagerImpl.java:126) > at > com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:209) > at > com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:249) > at > com.sun.net.ssl.internal.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:1188) > ... 29 more > Caused by: sun.security.provider.certpath.SunCertPathBuilderException: > unable to find valid certification path to requested target > at > sun.security.provider.certpath.SunCertPathBuilder.engineBuild(SunCertPathBuilder.java:174) > at java.security.cert.CertPathBuilder.build(CertPathBuilder.java:238) > at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:318) > ... 35 more > 11/11/2013 09:55:23 com.gargoylesoftware.htmlunit.html.BaseFrameElement > loadInnerPageIfPossible > SEVERE: IOException when getting content for iframe: url=[ > https://acw.sciverse.com/SSOCore/update?acw=61d5d88a1164241502b86549eb96594e1fe0521%7C%24%7CJaYnPDv2odsjkuRTDTxw4aRRMXBZiJ8Mr3nxjU06KnmV2KWzVYCF9l%2FJd6PrZZXDpLLlYpMRbbWjmt81zQFCVK2W%2F%2B9o4%2Fzy > ] > javax.net.ssl.SSLHandshakeException: > sun.security.validator.ValidatorException: PKIX path building failed: > sun.security.provider.certpath.SunCertPathBuilderException: unable to find > valid certification path to requested target > at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:174) > at > com.sun.net.ssl.internal.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1747) > .... > at > com.gargoylesoftware.htmlunit.HttpWebConnection.getResponse(HttpWebConnection.java:167) > at > com.gargoylesoftware.htmlunit.WebClient.loadWebResponseFromWebConnection(WebClient.java:1281) > at > com.gargoylesoftware.htmlunit.WebClient.loadWebResponse(WebClient.java:1198) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:307) > at > com.gargoylesoftware.htmlunit.html.BaseFrameElement.loadInnerPageIfPossible(BaseFrameElement.java:174) > at > com.gargoylesoftware.htmlunit.html.BaseFrameElement.loadInnerPage(BaseFrameElement.java:112) > at > com.gargoylesoftware.htmlunit.html.HtmlPage.loadFrames(HtmlPage.java:1880) > at > com.gargoylesoftware.htmlunit.html.HtmlPage.initialize(HtmlPage.java:232) > at > com.gargoylesoftware.htmlunit.WebClient.loadWebResponseInto(WebClient.java:444) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:311) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:376) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:361) > at test.Test.main(Test.java:15) > Caused by: sun.security.validator.ValidatorException: PKIX path building > failed: sun.security.provider.certpath.SunCertPathBuilderException: unable > to find valid certification path to requested target > at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:323) > at > sun.security.validator.PKIXValidator.engineValidate(PKIXValidator.java:217) > at sun.security.validator.Validator.validate(Validator.java:218) > at > com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.validate(X509TrustManagerImpl.java:126) > at > com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:209) > at > com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:249) > at > com.sun.net.ssl.internal.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:1188) > ... 29 more > Caused by: sun.security.provider.certpath.SunCertPathBuilderException: > unable to find valid certification path to requested target > at > sun.security.provider.certpath.SunCertPathBuilder.engineBuild(SunCertPathBuilder.java:174) > at java.security.cert.CertPathBuilder.build(CertPathBuilder.java:238) > at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:318) > ... 35 more > 11/11/2013 09:55:24 com.gargoylesoftware.htmlunit.html.BaseFrameElement > loadInnerPageIfPossible > SEVERE: IOException when getting content for iframe: url=[ > https://acw.elsevier.com/SSOCore/update?acw=61d5d88a1164241502b86549eb96594e1fe0521%7C%24%7CJaYnPDv2odsjkuRTDTxw4aRRMXBZiJ8Mr3nxjU06KnmV2KWzVYCF9l%2FJd6PrZZXDpLLlYpMRbbWjmt81zQFCVK2W%2F%2B9o4%2Fzy > ] > javax.net.ssl.SSLHandshakeException: > sun.security.validator.ValidatorException: PKIX path building failed: > sun.security.provider.certpath.SunCertPathBuilderException: unable to find > valid certification path to requested target > at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:174) > ... > at > com.gargoylesoftware.htmlunit.HtmlUnitSSLSocketFactory.connectSocket(HtmlUnitSSLSocketFactory.java:153) > at > org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:178) > at > org.apache.http.impl.conn.ManagedClientConnectionImpl.open(ManagedClientConnectionImpl.java:304) > at > org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:610) > at > org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:445) > at > org.apache.http.impl.client.AbstractHttpClient.doExecute(AbstractHttpClient.java:863) > at > org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:72) > at > com.gargoylesoftware.htmlunit.HttpWebConnection.getResponse(HttpWebConnection.java:167) > at > com.gargoylesoftware.htmlunit.WebClient.loadWebResponseFromWebConnection(WebClient.java:1281) > at > com.gargoylesoftware.htmlunit.WebClient.loadWebResponse(WebClient.java:1198) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:307) > at > com.gargoylesoftware.htmlunit.html.BaseFrameElement.loadInnerPageIfPossible(BaseFrameElement.java:174) > at > com.gargoylesoftware.htmlunit.html.BaseFrameElement.loadInnerPage(BaseFrameElement.java:112) > at > com.gargoylesoftware.htmlunit.html.HtmlPage.loadFrames(HtmlPage.java:1880) > at > com.gargoylesoftware.htmlunit.html.HtmlPage.initialize(HtmlPage.java:232) > at > com.gargoylesoftware.htmlunit.WebClient.loadWebResponseInto(WebClient.java:444) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:311) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:376) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:361) > at test.Test.main(Test.java:15) > Caused by: sun.security.validator.ValidatorException: PKIX path building > failed: sun.security.provider.certpath.SunCertPathBuilderException: unable > to find valid certification path to requested target > at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:323) > at > sun.security.validator.PKIXValidator.engineValidate(PKIXValidator.java:217) > at sun.security.validator.Validator.validate(Validator.java:218) > at > com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.validate(X509TrustManagerImpl.java:126) > at > com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:209) > at > com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:249) > at > com.sun.net.ssl.internal.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:1188) > ... 29 more > Caused by: sun.security.provider.certpath.SunCertPathBuilderException: > unable to find valid certification path to requested target > at > sun.security.provider.certpath.SunCertPathBuilder.engineBuild(SunCertPathBuilder.java:174) > at java.security.cert.CertPathBuilder.build(CertPathBuilder.java:238) > at sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:318) > ... 35 more > 11/11/2013 09:55:24 com.gargoylesoftware.htmlunit.DefaultCssErrorHandler > error > ... > > 11/11/2013 09:55:24 > com.gargoylesoftware.htmlunit.javascript.StrictErrorReporter runtimeError > SEVERE: runtimeError: message=[An invalid or illegal selector was > specified (selector: '[id='ui-id-1'] ul:not(.ui-menu)' error: Invalid > selector: *[id="ui-id-1"] ul:not(*.ui-menu)).] sourceName=[ > http://cdn.els-cdn.com/sd/js/sdX_133aR4.js] line=[10] lineSource=[null] > lineOffset=[0] > 11/11/2013 09:55:24 com.gargoylesoftware.htmlunit.html.HtmlPage > loadExternalJavaScriptFile > SEVERE: Error loading JavaScript from [ > https://cdn.els-cdn.com/sd/js/adobe/s_code_131.js]. > javax.net.ssl.SSLException: hostname in certificate didn't match: < > cdn.els-cdn.com> != <a248.e.akamai.net> OR <*.akamaihd.net> OR <*. > akamaihd-staging.net> OR <a248.e.akamai.net> > at > org.apache.http.conn.ssl.AbstractVerifier.verify(AbstractVerifier.java:231) > at > org.apache.http.conn.ssl.BrowserCompatHostnameVerifier.verify(BrowserCompatHostnameVerifier.java:54) > ... > at > com.gargoylesoftware.htmlunit.html.HtmlPage.initialize(HtmlPage.java:265) > at > com.gargoylesoftware.htmlunit.WebClient.loadWebResponseInto(WebClient.java:444) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:311) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:376) > at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:361) > at test.Test.main(Test.java:15) > > Exception in thread "main" java.lang.NullPointerException > at > com.steadystate.css.dom.CSSStyleDeclarationImpl.getPropertyValue(CSSStyleDeclarationImpl.java:109) > at > com.gargoylesoftware.htmlunit.javascript.host.css.ComputedCSSStyleDeclaration.applyStyleFromSelector(ComputedCSSStyleDeclaration.java:225) > at > com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:242) > at > com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:218) > at > com.gargoylesoftware.htmlunit.javascript.host.Window.getComputedStyle(Window.java:1607) > ,,, > at com.gargoylesoftware.htmlunit.html.DomNode.asText(DomNode.java:760) > at test.Test.main(Test.java:16) > > |
From: Ahmed A. <asa...@ya...> - 2013-11-11 06:36:47
|
Hi, https://sourceforge.net/projects/htmlunit/ "Tickets" -> "Bugs" Yours, Ahmed ________________________________ From: "McCray, Ken" <Ken...@Mc...> To: "htm...@li..." <htm...@li...> Sent: Sunday, November 10, 2013 10:26 PM Subject: Re: [Htmlunit-user] Running an Applet and Processing JRE Challenges I am looking at the htmlunit pages and I don't see a way to submit a case for supporting applet execution via the new html5 tag. Can someone direct me? -----Original Message----- From: Ronald Brill [mailto:rb...@rb...] Sent: Monday, October 28, 2013 4:08 AM To: htm...@li... Subject: Re: [Htmlunit-user] Running an Applet and Processing JRE Challenges Hi Ken, did some checking of the html5 spec "The applet element is a Java-specific variant of the embed element. The applet element is now obsoleted so that all extension frameworks (Java, .NET, Flash, etc) are handled in a consistent manner. " So i think HtmlUnit has to move forward and make the embed tag support a bit more clever to support at least applets at the same level like the applet tag. But as always this requires some time to implement. Please open an issue for that. How fast do you need a solution for that? Do you like to provide a patch? At least some testcases? RBRi On Sun, 27 Oct 2013 21:33:37 +0000 McCray, Ken wrote: > >I think I see why the applet is not starting. HTMLUNIT does not look to >recognize this code > ><EMBED id = "sdcEmbed" type = "application/x-java-applet;version=1.4" >CODE = "rss.sdc.SdcApplet.class" ARCHIVE = >"SdcApplet.jar,tunnelhttp.jar,httptunnel.jar,rssjschnocrypt.jar,rssjsch >crypt.jar" WIDTH = 220 HEIGHT = 50 serverHost >="host.net" serverUPort="7891" securePort="22" >debugFlag ="false" userId ="xybest" sessionId ="24741" >disableIpConnect = "false" enableIpMapping = "true" >enableHostNameMapping = "false" mayscript="true" pluginspage = >"https://java.sun.com/products/plugin/index.html#download"> <NOEMBED> ></NOEMBED> </EMBED> > >As an applet. Is there a workaround for this? I can convert this tag to an applet tag but can I infuse that into the HTMLPage and execute it? > > > >-----Original Message----- >From: Ronald Brill [mailto:rb...@rb...] >Sent: Friday, October 25, 2013 12:29 PM >To: htm...@li... >Subject: Re: [Htmlunit-user] Running an Applet and Processing JRE >Challenges > >Ken, > >WETATOR has a simple support for applet checkin build in. We have at least one test suite that uses this. The idea is to do some regression testing because they had many classpath problem in the past. >If you like you can have a look at the code > >https://wetator.repositoryhosting.com/trac/wetator_wetator/browser/trun >k/wetator/src/org/wetator/commandset/IncubatorCommandSet.java#L276 > >You can ask for the applet from your code and this will start the applet livecycle. If this does not throw an exception you know that the applet was started. >Your code is in charge for stopping the applet. >And you get the Applet instance back, so you can do some method calling if you like. > > RBRi > > > >On Fri, 25 Oct 2013 16:08:29 +0000 McCray, Ken wrote: >> >>I am not sure if the applet is running because I don't get the normal >>access challenge from running the applet. If the applet generates a >>pop up requesting allow or do not allow how to I >trap that in htmlunit? >> >> >> >>-----Original Message----- >>From: Ronald Brill [mailto:rb...@rb...] >>Sent: Friday, October 25, 2013 11:56 AM >>To: Ahmed Ashour; htm...@li... >>Subject: Re: [Htmlunit-user] Running an Applet and Processing JRE >>Challenges >> >>Hi Ken, >> >>think that the support is not that limited. >>What do you like to do? >> >> RBRi >> >> >>On Fri, 25 Oct 2013 08:47:12 -0700 (PDT) Ahmed Ashour wrote: >>> >>>Hi Ken, >>> >>>There is minimal support for applets, why do you need to specify the JRE? >>> >>>You need to use webClient.getOptions().setAppletEnabled(true); >>> >>>Yours, >>>Ahmed Ashour >>> >>>________________________________ >>> From: "McCray, Ken" <Ken...@Mc...> >>>To: "htm...@li..." >>><htm...@li...> >>>Sent: Friday, October 25, 2013 5:00 PM >>>Subject: [Htmlunit-user] Running an Applet and Processing JRE >>>Challenges >>> >>> >>> >>> >>> >>>Does HTMLUNIT support the execution of Applets. If so how do I specify the JRE? >>>--------------------------------------------------------------------- >>>- >>>- >>>------- >>>October Webinars: Code for Performance Free Intel webinars can help >>>you accelerate application performance. >>>Explore tips for MPI, OpenMP, advanced profiling, and more. Get the >>>most from the latest Intel processors and coprocessors. See abstracts >>>and register > >>>http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg. >>>c l ktrk _______________________________________________ >>>Htmlunit-user mailing list >>>Htm...@li... >>>https://lists.sourceforge.net/lists/listinfo/htmlunit-user >>> >> >> >>---------------------------------------------------------------------- >>- >>------- >>October Webinars: Code for Performance Free Intel webinars can help >>you accelerate application performance. >>Explore tips for MPI, OpenMP, advanced profiling, and more. Get the >>most from the latest Intel processors and coprocessors. See abstracts >>and register > >http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg..c >lktrk >>_______________________________________________ >>Htmlunit-user mailing list >>Htm...@li... >>https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> >>---------------------------------------------------------------------- >>- >>------- >>October Webinars: Code for Performance Free Intel webinars can help >>you accelerate application performance. >>Explore tips for MPI, OpenMP, advanced profiling, and more. Get the >>most from the latest Intel processors and coprocessors. See abstracts >>and register > >>http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.c >>l ktrk _______________________________________________ >>Htmlunit-user mailing list >>Htm...@li... >>https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> > > >----------------------------------------------------------------------- >------- >October Webinars: Code for Performance >Free Intel webinars can help you accelerate application performance. >Explore tips for MPI, OpenMP, advanced profiling, and more. Get the >most from the latest Intel processors and coprocessors. See abstracts >and register > >http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg..c >lktrk _______________________________________________ >Htmlunit-user mailing list >Htm...@li... >https://lists.sourceforge.net/lists/listinfo/htmlunit-user > >----------------------------------------------------------------------- >------- >October Webinars: Code for Performance >Free Intel webinars can help you accelerate application performance. >Explore tips for MPI, OpenMP, advanced profiling, and more. Get the >most from the latest Intel processors and coprocessors. See abstracts >and register > >http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.cl >ktrk _______________________________________________ >Htmlunit-user mailing list >Htm...@li... >https://lists.sourceforge.net/lists/listinfo/htmlunit-user > ------------------------------------------------------------------------------ October Webinars: Code for Performance Free Intel webinars can help you accelerate application performance. Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk _______________________________________________ Htmlunit-user mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/htmlunit-user ------------------------------------------------------------------------------ November Webinars for C, C++, Fortran Developers Accelerate application performance with scalable programming models. Explore techniques for threading, error checking, porting, and tuning. Get the most from the latest Intel processors and coprocessors. See abstracts and register http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk _______________________________________________ Htmlunit-user mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/htmlunit-user |
From: McCray, K. <Ken...@Mc...> - 2013-11-10 19:26:46
|
I am looking at the htmlunit pages and I don't see a way to submit a case for supporting applet execution via the new html5 tag. Can someone direct me? -----Original Message----- From: Ronald Brill [mailto:rb...@rb...] Sent: Monday, October 28, 2013 4:08 AM To: htm...@li... Subject: Re: [Htmlunit-user] Running an Applet and Processing JRE Challenges Hi Ken, did some checking of the html5 spec "The applet element is a Java-specific variant of the embed element. The applet element is now obsoleted so that all extension frameworks (Java, .NET, Flash, etc) are handled in a consistent manner. " So i think HtmlUnit has to move forward and make the embed tag support a bit more clever to support at least applets at the same level like the applet tag. But as always this requires some time to implement. Please open an issue for that. How fast do you need a solution for that? Do you like to provide a patch? At least some testcases? RBRi On Sun, 27 Oct 2013 21:33:37 +0000 McCray, Ken wrote: > >I think I see why the applet is not starting. HTMLUNIT does not look to >recognize this code > ><EMBED id = "sdcEmbed" type = "application/x-java-applet;version=1.4" >CODE = "rss.sdc.SdcApplet.class" ARCHIVE = >"SdcApplet.jar,tunnelhttp.jar,httptunnel.jar,rssjschnocrypt.jar,rssjsch >crypt.jar" WIDTH = 220 HEIGHT = 50 serverHost >="host.net" serverUPort="7891" securePort="22" >debugFlag ="false" userId ="xybest" sessionId ="24741" >disableIpConnect = "false" enableIpMapping = "true" >enableHostNameMapping = "false" mayscript="true" pluginspage = >"https://java.sun.com/products/plugin/index.html#download"> <NOEMBED> ></NOEMBED> </EMBED> > >As an applet. Is there a workaround for this? I can convert this tag to an applet tag but can I infuse that into the HTMLPage and execute it? > > > >-----Original Message----- >From: Ronald Brill [mailto:rb...@rb...] >Sent: Friday, October 25, 2013 12:29 PM >To: htm...@li... >Subject: Re: [Htmlunit-user] Running an Applet and Processing JRE >Challenges > >Ken, > >WETATOR has a simple support for applet checkin build in. We have at least one test suite that uses this. The idea is to do some regression testing because they had many classpath problem in the past. >If you like you can have a look at the code > >https://wetator.repositoryhosting.com/trac/wetator_wetator/browser/trun >k/wetator/src/org/wetator/commandset/IncubatorCommandSet.java#L276 > >You can ask for the applet from your code and this will start the applet livecycle. If this does not throw an exception you know that the applet was started. >Your code is in charge for stopping the applet. >And you get the Applet instance back, so you can do some method calling if you like. > > RBRi > > > >On Fri, 25 Oct 2013 16:08:29 +0000 McCray, Ken wrote: >> >>I am not sure if the applet is running because I don't get the normal >>access challenge from running the applet. If the applet generates a >>pop up requesting allow or do not allow how to I >trap that in htmlunit? >> >> >> >>-----Original Message----- >>From: Ronald Brill [mailto:rb...@rb...] >>Sent: Friday, October 25, 2013 11:56 AM >>To: Ahmed Ashour; htm...@li... >>Subject: Re: [Htmlunit-user] Running an Applet and Processing JRE >>Challenges >> >>Hi Ken, >> >>think that the support is not that limited. >>What do you like to do? >> >> RBRi >> >> >>On Fri, 25 Oct 2013 08:47:12 -0700 (PDT) Ahmed Ashour wrote: >>> >>>Hi Ken, >>> >>>There is minimal support for applets, why do you need to specify the JRE? >>> >>>You need to use webClient.getOptions().setAppletEnabled(true); >>> >>>Yours, >>>Ahmed Ashour >>> >>>________________________________ >>> From: "McCray, Ken" <Ken...@Mc...> >>>To: "htm...@li..." >>><htm...@li...> >>>Sent: Friday, October 25, 2013 5:00 PM >>>Subject: [Htmlunit-user] Running an Applet and Processing JRE >>>Challenges >>> >>> >>> >>> >>> >>>Does HTMLUNIT support the execution of Applets. If so how do I specify the JRE? >>>--------------------------------------------------------------------- >>>- >>>- >>>------- >>>October Webinars: Code for Performance Free Intel webinars can help >>>you accelerate application performance. >>>Explore tips for MPI, OpenMP, advanced profiling, and more. Get the >>>most from the latest Intel processors and coprocessors. See abstracts >>>and register > >>>http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg. >>>c l ktrk _______________________________________________ >>>Htmlunit-user mailing list >>>Htm...@li... >>>https://lists.sourceforge.net/lists/listinfo/htmlunit-user >>> >> >> >>---------------------------------------------------------------------- >>- >>------- >>October Webinars: Code for Performance Free Intel webinars can help >>you accelerate application performance. >>Explore tips for MPI, OpenMP, advanced profiling, and more. Get the >>most from the latest Intel processors and coprocessors. See abstracts >>and register > >http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg..c >lktrk >>_______________________________________________ >>Htmlunit-user mailing list >>Htm...@li... >>https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> >>---------------------------------------------------------------------- >>- >>------- >>October Webinars: Code for Performance Free Intel webinars can help >>you accelerate application performance. >>Explore tips for MPI, OpenMP, advanced profiling, and more. Get the >>most from the latest Intel processors and coprocessors. See abstracts >>and register > >>http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.c >>l ktrk _______________________________________________ >>Htmlunit-user mailing list >>Htm...@li... >>https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> > > >----------------------------------------------------------------------- >------- >October Webinars: Code for Performance >Free Intel webinars can help you accelerate application performance. >Explore tips for MPI, OpenMP, advanced profiling, and more. Get the >most from the latest Intel processors and coprocessors. See abstracts >and register > >http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg..c >lktrk _______________________________________________ >Htmlunit-user mailing list >Htm...@li... >https://lists.sourceforge.net/lists/listinfo/htmlunit-user > >----------------------------------------------------------------------- >------- >October Webinars: Code for Performance >Free Intel webinars can help you accelerate application performance. >Explore tips for MPI, OpenMP, advanced profiling, and more. Get the >most from the latest Intel processors and coprocessors. See abstracts >and register > >http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.cl >ktrk _______________________________________________ >Htmlunit-user mailing list >Htm...@li... >https://lists.sourceforge.net/lists/listinfo/htmlunit-user > ------------------------------------------------------------------------------ October Webinars: Code for Performance Free Intel webinars can help you accelerate application performance. Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk _______________________________________________ Htmlunit-user mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/htmlunit-user |
From: bruce <bad...@gm...> - 2013-11-10 18:39:20
|
when I tried test cases in htmlunit.. and then selenium, they were both ~ the same in terms of speed (as I recall). However, when I jumped/started using phantonjs/casperjs to run test to screen scrape, way! faster!! But keep in mind, my purpose/tests where primarily screen scraping, where I need to access the dynamic jscript to be able to to created the page. Once I got the page, other processes outside the java/jscript apps did the parsing On Sun, Nov 10, 2013 at 12:11 PM, Ahmed Ashour <asa...@ya...> wrote: > Hi Bruce, > > HtmlUnit is the only one as far as I humbly know that 'simulates' real > browsers, by handling JavaScript, CSS, DOM, etc. > > Selenium/Webdriver controls 'actual' real browsers, and HtmlUnitDriver is a > wrapper over HtmlUnit. > > However, you could write your test cases with WebDriver, and then easily > change to real browsers/HtmlUnit whenever necessary. > > Yours, > Ahmed > > On Nov 10, 2013, at 6:24 PM, bruce <bad...@gm...> wrote: > > Hi. > > Been following the htmlunit app for a bit, used it a few years ago. > > Can someone with a good understanding of Htmlunit explain why/when > someone would use Htmlunit over something like selenium/casper.. > > As far as I can tell, Htmlunit and Selenium are essentially the same, > both being java based, with the ability to run headless > browser/session tests. > > As far as i can tell, Selenium appears to be the more/larger supported app. > > Am I missing something. > > thanks > > ------------------------------------------------------------------------------ > November Webinars for C, C++, Fortran Developers > Accelerate application performance with scalable programming models. Explore > techniques for threading, error checking, porting, and tuning. Get the most > from the latest Intel processors and coprocessors. See abstracts and > register > http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user > > > ------------------------------------------------------------------------------ > November Webinars for C, C++, Fortran Developers > Accelerate application performance with scalable programming models. Explore > techniques for threading, error checking, porting, and tuning. Get the most > from the latest Intel processors and coprocessors. See abstracts and > register > http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user > |
From: Nitin T. <nt...@ne...> - 2013-11-10 17:37:15
|
Hi Ahmed, I am doing it this way - HtmlForm form = (HtmlForm)searchPage.getElementById("flights-form"); if(form != null) { (form.getInputByName("MDCity_1")).setValueAttribute("Los Angeles, CA - Los Angeles Intl Airport (LAX)"); (form.getInputByName("MDCity_2")).setValueAttribute("New York City, NY - All Airports (NYC)"); (form.getInputByName("DepDateMD1")).setValueAttribute("11/15/2013"); HtmlButton searchButton = form.getElementById("air-btn-submit-retl"); searchResultPage = searchButton.click(); while(!searchResultPage.getUrl().toString().contains("airlines")) { System.out.println("Waiting!!"); Thread t = Thread.currentThread(); t.sleep(60 * 1000); searchResultPage = (HtmlPage)webClient.getCurrentWindow().getEnclosedPage(); System.out.println("Page Content: " + searchResultPage.asXml()); } It is printing a blank page every time, and is not taking me to the results page. Please suggest what I am doing wrong. Regards Nitin On Sunday, 10-11-2013 on 17:12 Ahmed Ashour wrote: Hi Nitin, How do you fill the form? The below doesn't work HtmlPage page = webClient.getPage("http://www.priceline.com/flights/"); page.getHtmlElementById("air-loc-from").setValueAttribute("Los Angeles, CA - Los Angeles Intl Airport (LAX)"); page.getHtmlElementById("air-loc-to").setValueAttribute("New York City, NY - All Airports (NYC)"); page.getHtmlElementById("return-date").setValueAttribute("12/01/2013"); HtmlPage page2 = page.getHtmlElementById("air-submit-btn").click(); Ahmed ------------------------- FROM: Nitin Tomer TO: htm...@li... SENT: Wednesday, November 6, 2013 4:39 PM SUBJECT: [Htmlunit-user] Not able to submit a form Hi, I am trying to submit a form on this link - http://www.priceline.com/flights/ I am giving values - from (LAX), to (NYC) and date as 07-Nov-2013. It is giving me results when I do it by browser but returns the same page when I try this with HtmlUnit. I saw that the form had this tag - The button tag is - Search Flights Why is this form not being submitted? Is it because the form has an xaction instead of action? Please help. Regards Nitin Disclaimer :- This e-mail and any attachment may contain confidential, proprietary or legally privileged information. If you are not the original intended recipient and have erroneously received this message, you are prohibited from using, copying, altering or disclosing the content of this message. Please delete it immediately and notify the sender. Newgen Software Technologies Ltd (NSTL) accepts no responsibilities for loss or damage arising from the use of the information transmitted by this email including damages from virus and further acknowledges that no binding nature of the message shall be implied or assumed unless the sender does so expressly with due authority of NSTL. ------------------------------------------------------------------------------ November Webinars for C, C++, Fortran Developers Accelerate application performance with scalable programming models. Explore techniques for threading, error checking, porting, and tuning. Get the most from the latest Intel processors and coprocessors. See abstracts and register http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk _______________________________________________ Htmlunit-user mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/htmlunit-user Disclaimer :- This e-mail and any attachment may contain confidential, proprietary or legally privileged information. If you are not the original intended recipient and have erroneously received this message, you are prohibited from using, copying, altering or disclosing the content of this message. Please delete it immediately and notify the sender. Newgen Software Technologies Ltd (NSTL) accepts no responsibilities for loss or damage arising from the use of the information transmitted by this email including damages from virus and further acknowledges that no binding nature of the message shall be implied or assumed unless the sender does so expressly with due authority of NSTL. |
From: Tony Z. <ton...@gm...> - 2013-11-10 17:34:06
|
Would it be safe to assume that HTMLUnit is more resource efficient as it does not paint the screen as well? I use HTMLUnit extensively, just curious how to phrase the pros and cons to others. Tony On Sun, Nov 10, 2013 at 11:11 AM, Ahmed Ashour <asa...@ya...> wrote: > Hi Bruce, > > HtmlUnit is the only one as far as I humbly know that 'simulates' real > browsers, by handling JavaScript, CSS, DOM, etc. > > Selenium/Webdriver controls 'actual' real browsers, and HtmlUnitDriver is > a wrapper over HtmlUnit. > > However, you could write your test cases with WebDriver, and then easily > change to real browsers/HtmlUnit whenever necessary. > > Yours, > Ahmed > > On Nov 10, 2013, at 6:24 PM, bruce <bad...@gm...> wrote: > > Hi. > > Been following the htmlunit app for a bit, used it a few years ago. > > Can someone with a good understanding of Htmlunit explain why/when > someone would use Htmlunit over something like selenium/casper.. > > As far as I can tell, Htmlunit and Selenium are essentially the same, > both being java based, with the ability to run headless > browser/session tests. > > As far as i can tell, Selenium appears to be the more/larger supported app. > > Am I missing something. > > thanks > > > ------------------------------------------------------------------------------ > November Webinars for C, C++, Fortran Developers > Accelerate application performance with scalable programming models. > Explore > techniques for threading, error checking, porting, and tuning. Get the > most > from the latest Intel processors and coprocessors. See abstracts and > register > http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user > > > > ------------------------------------------------------------------------------ > November Webinars for C, C++, Fortran Developers > Accelerate application performance with scalable programming models. > Explore > techniques for threading, error checking, porting, and tuning. Get the most > from the latest Intel processors and coprocessors. See abstracts and > register > http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user > > |
From: Ahmed A. <asa...@ya...> - 2013-11-10 17:29:24
|
Please do. Ahmed > On Nov 10, 2013, at 5:53 PM, David Michael Gang <mic...@gm...> wrote: > > Hi, > > I am already using htmlunit 2.13. > Should i try the 2.14 snapshot? > > Thanks, > David > > >> On Sun, Nov 10, 2013 at 4:49 PM, <htm...@li...> wrote: >> Send Htmlunit-user mailing list submissions to >> htm...@li... >> >> To subscribe or unsubscribe via the World Wide Web, visit >> https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> or, via email, send a message with subject or body 'help' to >> htm...@li... >> >> You can reach the person managing the list at >> htm...@li... >> >> When replying, please edit your Subject line so it is more specific >> than "Re: Contents of Htmlunit-user digest..." >> >> >> Today's Topics: >> >> 1. exception when trying to get page with htmlunit >> (David Michael Gang) >> 2. Re: exception when trying to get page with htmlunit (Ahmed Ashour) >> >> >> ---------------------------------------------------------------------- >> >> Message: 1 >> Date: Sun, 10 Nov 2013 16:40:12 +0200 >> From: David Michael Gang <mic...@gm...> >> Subject: [Htmlunit-user] exception when trying to get page with >> htmlunit >> To: htm...@li... >> Message-ID: >> <CAJ...@ma...> >> Content-Type: text/plain; charset="iso-8859-1" >> >> Hi all, >> >> I have the following code: >> public static void main(String[] args) throws >> FailingHttpStatusCodeException, MalformedURLException, IOException { >> >> WebClient w = new WebClient(); >> HtmlPage p = w.getPage(" >> https://www.sciencedirect.com/science/book/9780121346454"); >> System.out.println(p.asText()); >> >> } >> >> I get the error: >> log4j:WARN No appenders could be found for logger >> (com.gargoylesoftware.htmlunit.WebClient). >> log4j:WARN Please initialize the log4j system properly. >> log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for >> more info. >> null [0:0] Error in expression. (Invalid token "<EOF>". Was expecting one >> of: <NUMBER>, "inherit", <IDENT>, <STRING>, <PLUS>, <HASH>, <EMS>, <EXS>, >> <LENGTH_PX>, <LENGTH_CM>, <LENGTH_MM>, <LENGTH_IN>, <LENGTH_PT>, >> <LENGTH_PC>, <ANGLE_DEG>, <ANGLE_RAD>, <ANGLE_GRAD>, <TIME_MS>, <TIME_S>, >> <FREQ_HZ>, <FREQ_KHZ>, <PERCENTAGE>, <DIMENSION>, <URI>, <FUNCTION>, "-".) >> Exception in thread "main" java.lang.NullPointerException >> at >> com.steadystate.css.dom.CSSStyleDeclarationImpl.getPropertyValue(CSSStyleDeclarationImpl.java:109) >> at >> com.gargoylesoftware.htmlunit.javascript.host.css.ComputedCSSStyleDeclaration.applyStyleFromSelector(ComputedCSSStyleDeclaration.java:224) >> at >> com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:240) >> at >> com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:216) >> at >> com.gargoylesoftware.htmlunit.javascript.host.Window.getComputedStyle(Window.java:1606) >> at >> com.gargoylesoftware.htmlunit.javascript.host.Element.getCurrentStyle(Element.java:545) >> at >> com.gargoylesoftware.htmlunit.html.DomNode.isDisplayed(DomNode.java:712) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.isVisible(HtmlSerializer.java:377) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendText(HtmlSerializer.java:371) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:126) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendHtmlUnorderedList(HtmlSerializer.java:229) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:188) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> at >> com.gargoylesoftware.htmlunit.html.HtmlSerializer.asText(HtmlSerializer.java:57) >> at com.gargoylesoftware.htmlunit.html.DomNode.asText(DomNode.java:760) >> at utils.ElsevierTest.main(ElsevierTest.java:29) >> >> I am using htmlunit 2.13. >> Is this a defect in htmlunit or a bad page? >> I can see the page with ie8. >> >> Thanks, >> David >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> >> ------------------------------ >> >> Message: 2 >> Date: Sun, 10 Nov 2013 06:49:40 -0800 (PST) >> From: Ahmed Ashour <asa...@ya...> >> Subject: Re: [Htmlunit-user] exception when trying to get page with >> htmlunit >> To: "htm...@li..." >> <htm...@li...> >> Message-ID: >> <138...@we...> >> Content-Type: text/plain; charset="iso-8859-1" >> >> Hi David, >> >> I get different result with SVN version. >> >> Please update to HtmlUnit 2.13 or get latest from?http://build.canoo.com/htmlunit/artifacts/ >> >> Yours, >> Ahmed >> >> ________________________________ >> From: David Michael Gang <mic...@gm...> >> To: htm...@li... >> Sent: Sunday, November 10, 2013 5:40 PM >> Subject: [Htmlunit-user] exception when trying to get page with htmlunit >> >> >> >> Hi all, >> >> I have the following code: >> public static void main(String[] args) throws FailingHttpStatusCodeException, MalformedURLException, IOException { >> >> ??? WebClient w = new WebClient(); >> ??? HtmlPage p = w.getPage("https://www.sciencedirect.com/science/book/9780121346454"); >> ??? System.out.println(p.asText()); >> ?? >> } >> >> I get the error: >> log4j:WARN No appenders could be found for logger (com.gargoylesoftware.htmlunit.WebClient). >> log4j:WARN Please initialize the log4j system properly. >> log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info. >> null [0:0] Error in expression. (Invalid token "<EOF>". Was expecting one of: <NUMBER>, "inherit", <IDENT>, <STRING>, <PLUS>, <HASH>, <EMS>, <EXS>, <LENGTH_PX>, <LENGTH_CM>, <LENGTH_MM>, <LENGTH_IN>, <LENGTH_PT>, <LENGTH_PC>, <ANGLE_DEG>, <ANGLE_RAD>, <ANGLE_GRAD>, <TIME_MS>, <TIME_S>, <FREQ_HZ>, <FREQ_KHZ>, <PERCENTAGE>, <DIMENSION>, <URI>, <FUNCTION>, "-".) >> Exception in thread "main" java.lang.NullPointerException >> ??? at com.steadystate.css.dom.CSSStyleDeclarationImpl.getPropertyValue(CSSStyleDeclarationImpl.java:109) >> ??? at com.gargoylesoftware.htmlunit.javascript.host.css.ComputedCSSStyleDeclaration.applyStyleFromSelector(ComputedCSSStyleDeclaration.java:224) >> ??? at com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:240) >> ??? at com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:216) >> ??? at com.gargoylesoftware.htmlunit.javascript.host.Window.getComputedStyle(Window.java:1606) >> ??? at com.gargoylesoftware.htmlunit.javascript.host.Element.getCurrentStyle(Element.java:545) >> ??? at com.gargoylesoftware.htmlunit.html.DomNode.isDisplayed(DomNode.java:712) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.isVisible(HtmlSerializer.java:377) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendText(HtmlSerializer.java:371) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:126) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendHtmlUnorderedList(HtmlSerializer.java:229) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:188) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) >> ??? at com.gargoylesoftware.htmlunit.html.HtmlSerializer.asText(HtmlSerializer.java:57) >> ??? at com.gargoylesoftware.htmlunit.html.DomNode.asText(DomNode.java:760) >> ??? at utils.ElsevierTest.main(ElsevierTest.java:29) >> >> I am using htmlunit 2.13. >> >> Is this a defect in htmlunit or a bad page? >> >> I can see the page with ie8. >> >> Thanks, >> David >> >> >> ------------------------------------------------------------------------------ >> November Webinars for C, C++, Fortran Developers >> Accelerate application performance with scalable programming models. Explore >> techniques for threading, error checking, porting, and tuning. Get the most >> from the latest Intel processors and coprocessors. See abstracts and register >> http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk >> _______________________________________________ >> Htmlunit-user mailing list >> Htm...@li... >> https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> -------------- next part -------------- >> An HTML attachment was scrubbed... >> >> ------------------------------ >> >> ------------------------------------------------------------------------------ >> November Webinars for C, C++, Fortran Developers >> Accelerate application performance with scalable programming models. Explore >> techniques for threading, error checking, porting, and tuning. Get the most >> from the latest Intel processors and coprocessors. See abstracts and register >> http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk >> >> ------------------------------ >> >> _______________________________________________ >> Htmlunit-user mailing list >> Htm...@li... >> https://lists.sourceforge.net/lists/listinfo/htmlunit-user >> >> >> End of Htmlunit-user Digest, Vol 90, Issue 2 >> ******************************************** > > ------------------------------------------------------------------------------ > November Webinars for C, C++, Fortran Developers > Accelerate application performance with scalable programming models. Explore > techniques for threading, error checking, porting, and tuning. Get the most > from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user |
From: Ahmed A. <asa...@ya...> - 2013-11-10 17:23:37
|
The previous answer is what. Why: The simulator is faster in many cases, as there is no initial loading of browser, no rendering, etc. however, that's at the expense of following exact real browser behavior sometimes. I would say, try both, and decide yourself; one line in WebDriver is the needed change :) Ahmed > On Nov 10, 2013, at 8:11 PM, Ahmed Ashour <asa...@ya...> wrote: > > Hi Bruce, > > HtmlUnit is the only one as far as I humbly know that 'simulates' real browsers, by handling JavaScript, CSS, DOM, etc. > > Selenium/Webdriver controls 'actual' real browsers, and HtmlUnitDriver is a wrapper over HtmlUnit. > > However, you could write your test cases with WebDriver, and then easily change to real browsers/HtmlUnit whenever necessary. > > Yours, > Ahmed > >> On Nov 10, 2013, at 6:24 PM, bruce <bad...@gm...> wrote: >> >> Hi. >> >> Been following the htmlunit app for a bit, used it a few years ago. >> >> Can someone with a good understanding of Htmlunit explain why/when >> someone would use Htmlunit over something like selenium/casper.. >> >> As far as I can tell, Htmlunit and Selenium are essentially the same, >> both being java based, with the ability to run headless >> browser/session tests. >> >> As far as i can tell, Selenium appears to be the more/larger supported app. >> >> Am I missing something. >> >> thanks >> >> ------------------------------------------------------------------------------ >> November Webinars for C, C++, Fortran Developers >> Accelerate application performance with scalable programming models. Explore >> techniques for threading, error checking, porting, and tuning. Get the most >> from the latest Intel processors and coprocessors. See abstracts and register >> http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk >> _______________________________________________ >> Htmlunit-user mailing list >> Htm...@li... >> https://lists.sourceforge.net/lists/listinfo/htmlunit-user > ------------------------------------------------------------------------------ > November Webinars for C, C++, Fortran Developers > Accelerate application performance with scalable programming models. Explore > techniques for threading, error checking, porting, and tuning. Get the most > from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user |
From: Ahmed A. <asa...@ya...> - 2013-11-10 17:11:30
|
Hi Bruce, HtmlUnit is the only one as far as I humbly know that 'simulates' real browsers, by handling JavaScript, CSS, DOM, etc. Selenium/Webdriver controls 'actual' real browsers, and HtmlUnitDriver is a wrapper over HtmlUnit. However, you could write your test cases with WebDriver, and then easily change to real browsers/HtmlUnit whenever necessary. Yours, Ahmed > On Nov 10, 2013, at 6:24 PM, bruce <bad...@gm...> wrote: > > Hi. > > Been following the htmlunit app for a bit, used it a few years ago. > > Can someone with a good understanding of Htmlunit explain why/when > someone would use Htmlunit over something like selenium/casper.. > > As far as I can tell, Htmlunit and Selenium are essentially the same, > both being java based, with the ability to run headless > browser/session tests. > > As far as i can tell, Selenium appears to be the more/larger supported app. > > Am I missing something. > > thanks > > ------------------------------------------------------------------------------ > November Webinars for C, C++, Fortran Developers > Accelerate application performance with scalable programming models. Explore > techniques for threading, error checking, porting, and tuning. Get the most > from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user |
From: bruce <bad...@gm...> - 2013-11-10 15:24:17
|
Hi. Been following the htmlunit app for a bit, used it a few years ago. Can someone with a good understanding of Htmlunit explain why/when someone would use Htmlunit over something like selenium/casper.. As far as I can tell, Htmlunit and Selenium are essentially the same, both being java based, with the ability to run headless browser/session tests. As far as i can tell, Selenium appears to be the more/larger supported app. Am I missing something. thanks |
From: David M. G. <mic...@gm...> - 2013-11-10 14:54:08
|
Hi, I am already using htmlunit 2.13. Should i try the 2.14 snapshot? Thanks, David On Sun, Nov 10, 2013 at 4:49 PM, < htm...@li...> wrote: > Send Htmlunit-user mailing list submissions to > htm...@li... > > To subscribe or unsubscribe via the World Wide Web, visit > https://lists.sourceforge.net/lists/listinfo/htmlunit-user > or, via email, send a message with subject or body 'help' to > htm...@li... > > You can reach the person managing the list at > htm...@li... > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of Htmlunit-user digest..." > > > Today's Topics: > > 1. exception when trying to get page with htmlunit > (David Michael Gang) > 2. Re: exception when trying to get page with htmlunit (Ahmed Ashour) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Sun, 10 Nov 2013 16:40:12 +0200 > From: David Michael Gang <mic...@gm...> > Subject: [Htmlunit-user] exception when trying to get page with > htmlunit > To: htm...@li... > Message-ID: > < > CAJ...@ma...> > Content-Type: text/plain; charset="iso-8859-1" > > Hi all, > > I have the following code: > public static void main(String[] args) throws > FailingHttpStatusCodeException, MalformedURLException, IOException { > > WebClient w = new WebClient(); > HtmlPage p = w.getPage(" > https://www.sciencedirect.com/science/book/9780121346454"); > System.out.println(p.asText()); > > } > > I get the error: > log4j:WARN No appenders could be found for logger > (com.gargoylesoftware.htmlunit.WebClient). > log4j:WARN Please initialize the log4j system properly. > log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for > more info. > null [0:0] Error in expression. (Invalid token "<EOF>". Was expecting one > of: <NUMBER>, "inherit", <IDENT>, <STRING>, <PLUS>, <HASH>, <EMS>, <EXS>, > <LENGTH_PX>, <LENGTH_CM>, <LENGTH_MM>, <LENGTH_IN>, <LENGTH_PT>, > <LENGTH_PC>, <ANGLE_DEG>, <ANGLE_RAD>, <ANGLE_GRAD>, <TIME_MS>, <TIME_S>, > <FREQ_HZ>, <FREQ_KHZ>, <PERCENTAGE>, <DIMENSION>, <URI>, <FUNCTION>, "-".) > Exception in thread "main" java.lang.NullPointerException > at > > com.steadystate.css.dom.CSSStyleDeclarationImpl.getPropertyValue(CSSStyleDeclarationImpl.java:109) > at > > com.gargoylesoftware.htmlunit.javascript.host.css.ComputedCSSStyleDeclaration.applyStyleFromSelector(ComputedCSSStyleDeclaration.java:224) > at > > com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:240) > at > > com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:216) > at > > com.gargoylesoftware.htmlunit.javascript.host.Window.getComputedStyle(Window.java:1606) > at > > com.gargoylesoftware.htmlunit.javascript.host.Element.getCurrentStyle(Element.java:545) > at > com.gargoylesoftware.htmlunit.html.DomNode.isDisplayed(DomNode.java:712) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.isVisible(HtmlSerializer.java:377) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendText(HtmlSerializer.java:371) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:126) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendHtmlUnorderedList(HtmlSerializer.java:229) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:188) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > at > > com.gargoylesoftware.htmlunit.html.HtmlSerializer.asText(HtmlSerializer.java:57) > at com.gargoylesoftware.htmlunit.html.DomNode.asText(DomNode.java:760) > at utils.ElsevierTest.main(ElsevierTest.java:29) > > I am using htmlunit 2.13. > Is this a defect in htmlunit or a bad page? > I can see the page with ie8. > > Thanks, > David > -------------- next part -------------- > An HTML attachment was scrubbed... > > ------------------------------ > > Message: 2 > Date: Sun, 10 Nov 2013 06:49:40 -0800 (PST) > From: Ahmed Ashour <asa...@ya...> > Subject: Re: [Htmlunit-user] exception when trying to get page with > htmlunit > To: "htm...@li..." > <htm...@li...> > Message-ID: > <138...@we...> > Content-Type: text/plain; charset="iso-8859-1" > > Hi David, > > I get different result with SVN version. > > Please update to HtmlUnit 2.13 or get latest from? > http://build.canoo.com/htmlunit/artifacts/ > > Yours, > Ahmed > > ________________________________ > From: David Michael Gang <mic...@gm...> > To: htm...@li... > Sent: Sunday, November 10, 2013 5:40 PM > Subject: [Htmlunit-user] exception when trying to get page with htmlunit > > > > Hi all, > > I have the following code: > public static void main(String[] args) throws > FailingHttpStatusCodeException, MalformedURLException, IOException { > > ??? WebClient w = new WebClient(); > ??? HtmlPage p = w.getPage(" > https://www.sciencedirect.com/science/book/9780121346454"); > ??? System.out.println(p.asText()); > ?? > } > > I get the error: > log4j:WARN No appenders could be found for logger > (com.gargoylesoftware.htmlunit.WebClient). > log4j:WARN Please initialize the log4j system properly. > log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for > more info. > null [0:0] Error in expression. (Invalid token "<EOF>". Was expecting one > of: <NUMBER>, "inherit", <IDENT>, <STRING>, <PLUS>, <HASH>, <EMS>, <EXS>, > <LENGTH_PX>, <LENGTH_CM>, <LENGTH_MM>, <LENGTH_IN>, <LENGTH_PT>, > <LENGTH_PC>, <ANGLE_DEG>, <ANGLE_RAD>, <ANGLE_GRAD>, <TIME_MS>, <TIME_S>, > <FREQ_HZ>, <FREQ_KHZ>, <PERCENTAGE>, <DIMENSION>, <URI>, <FUNCTION>, "-".) > Exception in thread "main" java.lang.NullPointerException > ??? at > com.steadystate.css.dom.CSSStyleDeclarationImpl.getPropertyValue(CSSStyleDeclarationImpl.java:109) > ??? at > com.gargoylesoftware.htmlunit.javascript.host.css.ComputedCSSStyleDeclaration.applyStyleFromSelector(ComputedCSSStyleDeclaration.java:224) > ??? at > com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:240) > ??? at > com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:216) > ??? at > com.gargoylesoftware.htmlunit.javascript.host.Window.getComputedStyle(Window.java:1606) > ??? at > com.gargoylesoftware.htmlunit.javascript.host.Element.getCurrentStyle(Element.java:545) > ??? at > com.gargoylesoftware.htmlunit.html.DomNode.isDisplayed(DomNode.java:712) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.isVisible(HtmlSerializer.java:377) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendText(HtmlSerializer.java:371) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:126) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendHtmlUnorderedList(HtmlSerializer.java:229) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:188) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) > ??? at > com.gargoylesoftware.htmlunit.html.HtmlSerializer.asText(HtmlSerializer.java:57) > ??? at com.gargoylesoftware.htmlunit.html.DomNode.asText(DomNode.java:760) > ??? at utils.ElsevierTest.main(ElsevierTest.java:29) > > I am using htmlunit 2.13. > > Is this a defect in htmlunit or a bad page? > > I can see the page with ie8. > > Thanks, > David > > > > ------------------------------------------------------------------------------ > November Webinars for C, C++, Fortran Developers > Accelerate application performance with scalable programming models. > Explore > techniques for threading, error checking, porting, and tuning. Get the most > from the latest Intel processors and coprocessors. See abstracts and > register > http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user > -------------- next part -------------- > An HTML attachment was scrubbed... > > ------------------------------ > > > ------------------------------------------------------------------------------ > November Webinars for C, C++, Fortran Developers > Accelerate application performance with scalable programming models. > Explore > techniques for threading, error checking, porting, and tuning. Get the most > from the latest Intel processors and coprocessors. See abstracts and > register > http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk > > ------------------------------ > > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user > > > End of Htmlunit-user Digest, Vol 90, Issue 2 > ******************************************** > |
From: Ahmed A. <asa...@ya...> - 2013-11-10 14:49:48
|
Hi David, I get different result with SVN version. Please update to HtmlUnit 2.13 or get latest from http://build.canoo.com/htmlunit/artifacts/ Yours, Ahmed ________________________________ From: David Michael Gang <mic...@gm...> To: htm...@li... Sent: Sunday, November 10, 2013 5:40 PM Subject: [Htmlunit-user] exception when trying to get page with htmlunit Hi all, I have the following code: public static void main(String[] args) throws FailingHttpStatusCodeException, MalformedURLException, IOException { WebClient w = new WebClient(); HtmlPage p = w.getPage("https://www.sciencedirect.com/science/book/9780121346454"); System.out.println(p.asText()); } I get the error: log4j:WARN No appenders could be found for logger (com.gargoylesoftware.htmlunit.WebClient). log4j:WARN Please initialize the log4j system properly. log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info. null [0:0] Error in expression. (Invalid token "<EOF>". Was expecting one of: <NUMBER>, "inherit", <IDENT>, <STRING>, <PLUS>, <HASH>, <EMS>, <EXS>, <LENGTH_PX>, <LENGTH_CM>, <LENGTH_MM>, <LENGTH_IN>, <LENGTH_PT>, <LENGTH_PC>, <ANGLE_DEG>, <ANGLE_RAD>, <ANGLE_GRAD>, <TIME_MS>, <TIME_S>, <FREQ_HZ>, <FREQ_KHZ>, <PERCENTAGE>, <DIMENSION>, <URI>, <FUNCTION>, "-".) Exception in thread "main" java.lang.NullPointerException at com.steadystate.css.dom.CSSStyleDeclarationImpl.getPropertyValue(CSSStyleDeclarationImpl.java:109) at com.gargoylesoftware.htmlunit.javascript.host.css.ComputedCSSStyleDeclaration.applyStyleFromSelector(ComputedCSSStyleDeclaration.java:224) at com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:240) at com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:216) at com.gargoylesoftware.htmlunit.javascript.host.Window.getComputedStyle(Window.java:1606) at com.gargoylesoftware.htmlunit.javascript.host.Element.getCurrentStyle(Element.java:545) at com.gargoylesoftware.htmlunit.html.DomNode.isDisplayed(DomNode.java:712) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.isVisible(HtmlSerializer.java:377) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendText(HtmlSerializer.java:371) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:126) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendHtmlUnorderedList(HtmlSerializer.java:229) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:188) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.asText(HtmlSerializer.java:57) at com.gargoylesoftware.htmlunit.html.DomNode.asText(DomNode.java:760) at utils.ElsevierTest.main(ElsevierTest.java:29) I am using htmlunit 2.13. Is this a defect in htmlunit or a bad page? I can see the page with ie8. Thanks, David ------------------------------------------------------------------------------ November Webinars for C, C++, Fortran Developers Accelerate application performance with scalable programming models. Explore techniques for threading, error checking, porting, and tuning. Get the most from the latest Intel processors and coprocessors. See abstracts and register http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk _______________________________________________ Htmlunit-user mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/htmlunit-user |
From: David M. G. <mic...@gm...> - 2013-11-10 14:40:21
|
Hi all, I have the following code: public static void main(String[] args) throws FailingHttpStatusCodeException, MalformedURLException, IOException { WebClient w = new WebClient(); HtmlPage p = w.getPage(" https://www.sciencedirect.com/science/book/9780121346454"); System.out.println(p.asText()); } I get the error: log4j:WARN No appenders could be found for logger (com.gargoylesoftware.htmlunit.WebClient). log4j:WARN Please initialize the log4j system properly. log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info. null [0:0] Error in expression. (Invalid token "<EOF>". Was expecting one of: <NUMBER>, "inherit", <IDENT>, <STRING>, <PLUS>, <HASH>, <EMS>, <EXS>, <LENGTH_PX>, <LENGTH_CM>, <LENGTH_MM>, <LENGTH_IN>, <LENGTH_PT>, <LENGTH_PC>, <ANGLE_DEG>, <ANGLE_RAD>, <ANGLE_GRAD>, <TIME_MS>, <TIME_S>, <FREQ_HZ>, <FREQ_KHZ>, <PERCENTAGE>, <DIMENSION>, <URI>, <FUNCTION>, "-".) Exception in thread "main" java.lang.NullPointerException at com.steadystate.css.dom.CSSStyleDeclarationImpl.getPropertyValue(CSSStyleDeclarationImpl.java:109) at com.gargoylesoftware.htmlunit.javascript.host.css.ComputedCSSStyleDeclaration.applyStyleFromSelector(ComputedCSSStyleDeclaration.java:224) at com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:240) at com.gargoylesoftware.htmlunit.javascript.host.css.CSSStyleSheet.modifyIfNecessary(CSSStyleSheet.java:216) at com.gargoylesoftware.htmlunit.javascript.host.Window.getComputedStyle(Window.java:1606) at com.gargoylesoftware.htmlunit.javascript.host.Element.getCurrentStyle(Element.java:545) at com.gargoylesoftware.htmlunit.html.DomNode.isDisplayed(DomNode.java:712) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.isVisible(HtmlSerializer.java:377) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendText(HtmlSerializer.java:371) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:126) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendHtmlUnorderedList(HtmlSerializer.java:229) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:188) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendChildren(HtmlSerializer.java:249) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.appendNode(HtmlSerializer.java:198) at com.gargoylesoftware.htmlunit.html.HtmlSerializer.asText(HtmlSerializer.java:57) at com.gargoylesoftware.htmlunit.html.DomNode.asText(DomNode.java:760) at utils.ElsevierTest.main(ElsevierTest.java:29) I am using htmlunit 2.13. Is this a defect in htmlunit or a bad page? I can see the page with ie8. Thanks, David |
From: Ahmed A. <asa...@ya...> - 2013-11-10 11:42:46
|
Hi Nitin, How do you fill the form? The below doesn't work HtmlPage page = webClient.getPage("http://www.priceline.com/flights/"); page.<HtmlInput>getHtmlElementById("air-loc-from").setValueAttribute("Los Angeles, CA - Los Angeles Intl Airport (LAX)"); page.<HtmlInput>getHtmlElementById("air-loc-to").setValueAttribute("New York City, NY - All Airports (NYC)"); page.<HtmlInput>getHtmlElementById("return-date").setValueAttribute("12/01/2013"); HtmlPage page2 = page.getHtmlElementById("air-submit-btn").click(); Ahmed ________________________________ From: Nitin Tomer <nt...@ne...> To: htm...@li... Sent: Wednesday, November 6, 2013 4:39 PM Subject: [Htmlunit-user] Not able to submit a form Hi, I am trying to submit a form on this link - http://www.priceline.com/flights/ I am giving values - from (LAX), to (NYC) and date as 07-Nov-2013. It is giving me results when I do it by browser but returns the same page when I try this with HtmlUnit. I saw that the form had this tag - <form class="searchform" pclnform="1" fmproduct="flights" data-section="FlightsForm" Xaction="/qp.asp" method="POST"> The button tag is - <button id="air-submit-btn" class="button primary medium" type="submit" value="retl">Search Flights</button> Why is this form not being submitted? Is it because the form has an xaction instead of action? Please help. Regards Nitin Disclaimer :- This e-mail and any attachment may contain confidential, proprietary or legally privileged information. If you are not the original intended recipient and have erroneously received this message, you are prohibited from using, copying, altering or disclosing the content of this message. Please delete it immediately and notify the sender. Newgen Software Technologies Ltd (NSTL) accepts no responsibilities for loss or damage arising from the use of the information transmitted by this email including damages from virus and further acknowledges that no binding nature of the message shall be implied or assumed unless the sender does so expressly with due authority of NSTL. ------------------------------------------------------------------------------ November Webinars for C, C++, Fortran Developers Accelerate application performance with scalable programming models. Explore techniques for threading, error checking, porting, and tuning. Get the most from the latest Intel processors and coprocessors. See abstracts and register http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk _______________________________________________ Htmlunit-user mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/htmlunit-user |
From: Nitin T. <nt...@ne...> - 2013-11-08 06:26:28
|
Please help... -----Original Message----- From: Nitin Tomer [mailto:nt...@ne...] Sent: Wednesday, November 06, 2013 7:09 PM To: htm...@li... Subject: [Htmlunit-user] Not able to submit a form Hi, I am trying to submit a form on this link - http://www.priceline.com/flights/ I am giving values - from (LAX), to (NYC) and date as 07-Nov-2013. It is giving me results when I do it by browser but returns the same page when I try this with HtmlUnit. I saw that the form had this tag - <form class="searchform" pclnform="1" fmproduct="flights" data-section="FlightsForm" Xaction="/qp.asp" method="POST"> The button tag is - <button id="air-submit-btn" class="button primary medium" type="submit" value="retl">Search Flights</button> Why is this form not being submitted? Is it because the form has an xaction instead of action? Please help. Regards Nitin Disclaimer :- This e-mail and any attachment may contain confidential, proprietary or legally privileged information. If you are not the original intended recipient and have erroneously received this message, you are prohibited from using, copying, altering or disclosing the content of this message. Please delete it immediately and notify the sender. Newgen Software Technologies Ltd (NSTL) accepts no responsibilities for loss or damage arising from the use of the information transmitted by this email including damages from virus and further acknowledges that no binding nature of the message shall be implied or assumed unless the sender does so expressly with due authority of NSTL. ---------------------------------------------------------------------------- -- November Webinars for C, C++, Fortran Developers Accelerate application performance with scalable programming models. Explore techniques for threading, error checking, porting, and tuning. Get the most from the latest Intel processors and coprocessors. See abstracts and register http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk _______________________________________________ Htmlunit-user mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/htmlunit-user Disclaimer :- This e-mail and any attachment may contain confidential, proprietary or legally privileged information. If you are not the original intended recipient and have erroneously received this message, you are prohibited from using, copying, altering or disclosing the content of this message. Please delete it immediately and notify the sender. Newgen Software Technologies Ltd (NSTL) accepts no responsibilities for loss or damage arising from the use of the information transmitted by this email including damages from virus and further acknowledges that no binding nature of the message shall be implied or assumed unless the sender does so expressly with due authority of NSTL. |
From: Ak1ra <fla...@gm...> - 2013-11-06 15:27:34
|
Hi Ronald, I have a similar issue with HtmlUnit v2.13. Code (Groovy): def url = 'http://www.nopi-restaurant.com/#/book-a-table' def webClient = new WebClient(BrowserVersion.FIREFOX_17) webClient.options.setThrowExceptionOnScriptError(false) def page = webClient.getPage(url) Output: | Error 2013-11-01 11:05:11,804 [JS executor for com.gargoylesoftware.htmlunit.WebClient@3f3f839c] ERROR javascript.StrictErrorReporter - runtimeError: message=[An invalid or illegal selector was specified (selector: 'div#backgrounds img:first' error: Invalid selector: div#backgrounds img:first).] sourceName=[https://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js] line=[100] lineSource=[null] lineOffset=[0] Did not observe any errors in the real browsers' console though... Thanks in advance, Dmitriy. >Oct 18, 2013; 10:21am — by Ronald Brill > Hi Eric, > >some more information might helpful. > >HtmlUnit version? >Is the page you are accessing is public so we can try to reproduce the problem? > > RBRi > >On Mon, 14 Oct 2013 11:03:54 -0700 Eric Peters wrote: > >> >>10:56:04.924 [main] ERROR c.g.h.javascript.StrictErrorReporter - >>runtimeError: message=[An invalid or illegal selector was specified >>(selector: '#advIdProgIdCombo option:selected' error: Invalid selector: >>*#advIdProgIdCombo option:selected).] sourceName=[ >>https://publisher.ebaypartnernetwork.com/common/js-16449593/min/jquery-1.3.2-min.js] >>line=[19] lineSource=[null] lineOffset=[0] >> >> >>Anyone know what browser feature might fix this? >> >>Thanks, >> >>Eric >> -- View this message in context: http://htmlunit.10904.n7.nabble.com/Invalid-selector-advIdProgIdCombo-option-selected-jquery-1-3-2-tp31892p32117.html Sent from the HtmlUnit - General mailing list archive at Nabble.com. |
From: Nitin T. <nt...@ne...> - 2013-11-06 13:57:45
|
Hi, I am trying to submit a form on this link - http://www.priceline.com/flights/ I am giving values - from (LAX), to (NYC) and date as 07-Nov-2013. It is giving me results when I do it by browser but returns the same page when I try this with HtmlUnit. I saw that the form had this tag - <form class="searchform" pclnform="1" fmproduct="flights" data-section="FlightsForm" Xaction="/qp.asp" method="POST"> The button tag is - <button id="air-submit-btn" class="button primary medium" type="submit" value="retl">Search Flights</button> Why is this form not being submitted? Is it because the form has an xaction instead of action? Please help. Regards Nitin Disclaimer :- This e-mail and any attachment may contain confidential, proprietary or legally privileged information. If you are not the original intended recipient and have erroneously received this message, you are prohibited from using, copying, altering or disclosing the content of this message. Please delete it immediately and notify the sender. Newgen Software Technologies Ltd (NSTL) accepts no responsibilities for loss or damage arising from the use of the information transmitted by this email including damages from virus and further acknowledges that no binding nature of the message shall be implied or assumed unless the sender does so expressly with due authority of NSTL. |
From: Ahmed A. <asa...@ya...> - 2013-10-28 19:19:55
|
Hi Andrew, htmlPage.getFullyQualifiedUrl(relativeURL) Ahmed ________________________________ From: Andrew Pennebaker <ape...@42...> To: HtmlUnit Users <htm...@li...> Sent: Monday, October 28, 2013 9:46 PM Subject: [Htmlunit-user] How can I get an anchor's "href" attribute, as an absolute URL? HtmlUnit offers anchor.getAttribute("href"), useful for collecting URLs from an HtmlPage. In JSoup, I can do anchor.attr("abs:href"), ensuring that the URLs are absolute rather than relative. Is there a way to do this in HtmlUnit? I suppose I could work around this by using Java's URL library to manually make all URLs absolute, but it would be nice if HtmlUnit offered a convenience syntax like JSoup. -- Cheers, Andrew Pennebaker ape...@42... ------------------------------------------------------------------------------ October Webinars: Code for Performance Free Intel webinars can help you accelerate application performance. Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk _______________________________________________ Htmlunit-user mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/htmlunit-user |
From: Andrew P. <ape...@42...> - 2013-10-28 19:06:38
|
Wow, that's pretty cool! What if HtmlPage provided some convenience methods: - List<DomElement> getElementByXPath(String xpathQuery) - List<Integer> getIntegersByXPath(String xpathQuery) - List<Boolean> getBooleanByXPath(String xpathQuery) On Mon, Oct 28, 2013 at 2:25 PM, Ahmed Ashour <asa...@ya...> wrote: > > :) > > Thanks for feedback. > > getByXPath() can return other things (rarely, but it can happen), like > number, boolean or even a string. > > Yours, > Ahmed > ------------------------------ > *From:* Andrew Pennebaker <ape...@42...> > *To:* HtmlUnit Users <htm...@li...> > *Sent:* Monday, October 28, 2013 8:56 PM > *Subject:* [Htmlunit-user] Suggestion for improving HtmlPage.getByXPath() > interface > > An HTML page contains only DomElements, so why does getByXPath() return > List<?> ? This method should be returning the fully specified type > List<DomElement>. For now, I'm using some wrapper code: > > public static List<DomElement> xpath(HtmlPage page, String query) { > List<DomElement> elements = new ArrayList<DomElement>(); > > List<?> objects = page.getByXPath(query); > > if (objects.getClass() == elements.getClass()) { > elements.addAll((List<DomElement>) objects); > } > > return elements; > } > > But it would be nice if HtmlUnit amended its interface appropriately. > > -- > Cheers, > > Andrew Pennebaker > ape...@42... > > > ------------------------------------------------------------------------------ > October Webinars: Code for Performance > Free Intel webinars can help you accelerate application performance. > Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most > from > the latest Intel processors and coprocessors. See abstracts and register > > http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user > > > > > ------------------------------------------------------------------------------ > October Webinars: Code for Performance > Free Intel webinars can help you accelerate application performance. > Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most > from > the latest Intel processors and coprocessors. See abstracts and register > > http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user > > -- Cheers, Andrew Pennebaker ape...@42... |
From: Andrew P. <ape...@42...> - 2013-10-28 18:46:47
|
HtmlUnit offers anchor.getAttribute("href"), useful for collecting URLs from an HtmlPage. In JSoup, I can do anchor.attr("abs:href"), ensuring that the URLs are absolute rather than relative. Is there a way to do this in HtmlUnit? I suppose I could work around this by using Java's URL library to manually make all URLs absolute, but it would be nice if HtmlUnit offered a convenience syntax like JSoup. -- Cheers, Andrew Pennebaker ape...@42... |
From: Ahmed A. <asa...@ya...> - 2013-10-28 18:25:23
|
:) Thanks for feedback. getByXPath() can return other things (rarely, but it can happen), like number, boolean or even a string. Yours, Ahmed ________________________________ From: Andrew Pennebaker <ape...@42...> To: HtmlUnit Users <htm...@li...> Sent: Monday, October 28, 2013 8:56 PM Subject: [Htmlunit-user] Suggestion for improving HtmlPage.getByXPath() interface An HTML page contains only DomElements, so why does getByXPath() return List<?> ? This method should be returning the fully specified type List<DomElement>. For now, I'm using some wrapper code: public static List<DomElement> xpath(HtmlPage page, String query) { List<DomElement> elements = new ArrayList<DomElement>(); List<?> objects = page.getByXPath(query); if (objects.getClass() == elements.getClass()) { elements.addAll((List<DomElement>) objects); } return elements; } But it would be nice if HtmlUnit amended its interface appropriately. -- Cheers, Andrew Pennebaker ape...@42... ------------------------------------------------------------------------------ October Webinars: Code for Performance Free Intel webinars can help you accelerate application performance. Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk _______________________________________________ Htmlunit-user mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/htmlunit-user |
From: Andrew P. <ape...@42...> - 2013-10-28 17:56:14
|
An HTML page contains only DomElements, so why does getByXPath() return List<?> ? This method should be returning the fully specified type List<DomElement>. For now, I'm using some wrapper code: public static List<DomElement> xpath(HtmlPage page, String query) { List<DomElement> elements = new ArrayList<DomElement>(); List<?> objects = page.getByXPath(query); if (objects.getClass() == elements.getClass()) { elements.addAll((List<DomElement>) objects); } return elements; } But it would be nice if HtmlUnit amended its interface appropriately. -- Cheers, Andrew Pennebaker ape...@42... |
From: Andrew P. <ape...@42...> - 2013-10-28 15:28:57
|
Is there a way to find out if another Maven project is referencing an older version of httpconnection? On Mon, Oct 28, 2013 at 11:07 AM, Ahmed Ashour <asa...@ya...> wrote: > Hi Andrew, > > - Delete your ~/.m2/repository folder > - Make a minimal project with only htmlunit dependency, and verify > - If still have an issue, please send that project. > > Ahmed > ------------------------------ > *From:* Andrew Pennebaker <ape...@42...> > *To:* HtmlUnit Users <htm...@li...> > *Sent:* Monday, October 28, 2013 4:51 PM > *Subject:* Re: [Htmlunit-user] NoClassDefFoundError: > org/apache/http/conn/scheme/SchemeSocketFactory > > I am able to mitigate this issue by manually specifying the httpcomponents > version in my pom: > > <dependency> > <groupId>net.sourceforge.htmlunit</groupId> > <artifactId>htmlunit</artifactId> > <version>2.13</version> > </dependency> > <!-- Fix dependency error --> > <dependency> > <groupId>org.apache.httpcomponents</groupId> > <artifactId>httpclient</artifactId> > <version>4.3.1</version> > </dependency> > > But I would like a more permanent solution. > > > On Mon, Oct 28, 2013 at 9:48 AM, Andrew Pennebaker <ape...@42...>wrote: > > When I try to use the WebClient() constructor, Java complains of an error. > > $ mvn compile > > java.lang.NoClassDefFoundError: > org/apache/http/conn/scheme/SchemeSocketFactory > at > com.gargoylesoftware.htmlunit.WebClient.createWebConnection(WebClient.java:1862) > at com.gargoylesoftware.htmlunit.WebClient.<init>(WebClient.java:129) > at com.gargoylesoftware.htmlunit.WebClient.<init>(WebClient.java:184) > > $ tail pom.xml > <dependency> > <groupId>net.sourceforge.htmlunit</groupId> > <artifactId>htmlunit</artifactId> > <version>2.13</version> > </dependency> > </dependencies> > </project> > > $ specs java os > Specs: > > specs 0.7 > https://github.com/mcandre/specs#readme > > mvn --version > Apache Maven 3.1.1 (0728685237757ffbf44136acec0402957f723d9a; 2013-09-17 > 11:22:22-0400) > Maven home: /usr/local/Cellar/maven/3.1.1/libexec > Java version: 1.6.0_65, vendor: Apple Inc. > Java home: /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home > Default locale: en_US, platform encoding: MacRoman > OS name: "mac os x", version: "10.9", arch: "x86_64", family: "mac" > > echo $CLASSPATH > > > echo $JAVA_HOME > /Library/Java/Home > > javac -version > javac 1.6.0_65 > > java -version > java version "1.6.0_65" > Java(TM) SE Runtime Environment (build 1.6.0_65-b14-462-11M4609) > Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-462, mixed mode) > > system_profiler SPSoftwareDataType | grep 'System Version' > System Version: OS X 10.9 (13A603) > > -- > Cheers, > > Andrew Pennebaker > ape...@42... > > > > > -- > Cheers, > > Andrew Pennebaker > ape...@42... > > > ------------------------------------------------------------------------------ > October Webinars: Code for Performance > Free Intel webinars can help you accelerate application performance. > Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most > from > the latest Intel processors and coprocessors. See abstracts and register > > http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk > > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user > > > > > ------------------------------------------------------------------------------ > October Webinars: Code for Performance > Free Intel webinars can help you accelerate application performance. > Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most > from > the latest Intel processors and coprocessors. See abstracts and register > > http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user > > -- Cheers, Andrew Pennebaker ape...@42... |
From: Ahmed A. <asa...@ya...> - 2013-10-28 15:19:04
|
Hi Praveen, If it is a JS error, so real browsers would throw an error. HtmlUnit is meant to exactly behave like real browsers. Please provide minimal lines that shows a different behavior, and it will be treated as a bug. If you want to change the incoming .js file, please read http://htmlunit.sourceforge.net/faq.html#HowToModifyRequestOrResponse Yours, Ahmed Ashour ________________________________ From: praveennin <pra...@gm...> To: htm...@li... Sent: Monday, October 28, 2013 4:54 PM Subject: Re: [Htmlunit-user] ReferenceError: "ssn" is not defined Ahmed, Yes. I knew it's an java script error. But Inspite of using some relevant possible htmlunit properties, I couldn't fix it. Can you suggest me some ideas? Thanks, Praveen -- View this message in context: http://htmlunit.10904.n7.nabble.com/ReferenceError-ssn-is-not-defined-tp32039p32045.html Sent from the HtmlUnit - General mailing list archive at Nabble.com. ------------------------------------------------------------------------------ October Webinars: Code for Performance Free Intel webinars can help you accelerate application performance. Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk _______________________________________________ Htmlunit-user mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/htmlunit-user |
From: Ahmed A. <asa...@ya...> - 2013-10-28 15:07:32
|
Hi Andrew, - Delete your ~/.m2/repository folder - Make a minimal project with only htmlunit dependency, and verify - If still have an issue, please send that project. Ahmed ________________________________ From: Andrew Pennebaker <ape...@42...> To: HtmlUnit Users <htm...@li...> Sent: Monday, October 28, 2013 4:51 PM Subject: Re: [Htmlunit-user] NoClassDefFoundError: org/apache/http/conn/scheme/SchemeSocketFactory I am able to mitigate this issue by manually specifying the httpcomponents version in my pom: <dependency> <groupId>net.sourceforge.htmlunit</groupId> <artifactId>htmlunit</artifactId> <version>2.13</version> </dependency> <!-- Fix dependency error --> <dependency> <groupId>org.apache.httpcomponents</groupId> <artifactId>httpclient</artifactId> <version>4.3.1</version> </dependency> But I would like a more permanent solution. On Mon, Oct 28, 2013 at 9:48 AM, Andrew Pennebaker <ape...@42...> wrote: When I try to use the WebClient() constructor, Java complains of an error. > > >$ mvn compile > > >java.lang.NoClassDefFoundError: org/apache/http/conn/scheme/SchemeSocketFactory >at com.gargoylesoftware.htmlunit.WebClient.createWebConnection(WebClient.java:1862) >at com.gargoylesoftware.htmlunit.WebClient.<init>(WebClient.java:129) >at com.gargoylesoftware.htmlunit.WebClient.<init>(WebClient.java:184) > > >$ tail pom.xml > <dependency> > <groupId>net.sourceforge.htmlunit</groupId> > <artifactId>htmlunit</artifactId> > <version>2.13</version> > </dependency> > </dependencies> ></project> > > >$ specs java os >Specs: > > >specs 0.7 >https://github.com/mcandre/specs#readme > > >mvn --version >Apache Maven 3.1.1 (0728685237757ffbf44136acec0402957f723d9a; 2013-09-17 11:22:22-0400) >Maven home: /usr/local/Cellar/maven/3.1.1/libexec >Java version: 1.6.0_65, vendor: Apple Inc. >Java home: /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home >Default locale: en_US, platform encoding: MacRoman >OS name: "mac os x", version: "10.9", arch: "x86_64", family: "mac" > > >echo $CLASSPATH > > > > >echo $JAVA_HOME >/Library/Java/Home > > >javac -version >javac 1.6.0_65 > > >java -version >java version "1.6.0_65" >Java(TM) SE Runtime Environment (build 1.6.0_65-b14-462-11M4609) >Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-462, mixed mode) > > >system_profiler SPSoftwareDataType | grep 'System Version' > System Version: OS X 10.9 (13A603) > >-- > >Cheers, > > >Andrew Pennebaker >ape...@42... -- Cheers, Andrew Pennebaker ape...@42... ------------------------------------------------------------------------------ October Webinars: Code for Performance Free Intel webinars can help you accelerate application performance. Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60135991&iu=/4140/ostg.clktrk _______________________________________________ Htmlunit-user mailing list Htm...@li... https://lists.sourceforge.net/lists/listinfo/htmlunit-user |