myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael Concini (JIRA)" <...@myfaces.apache.org>
Subject [jira] Created: (MYFACES-2745) Cannot set property "_mfProto" of null to "null" error with new javascript
Date Mon, 07 Jun 2010 13:07:38 GMT
Cannot set property "_mfProto" of null to "null" error with new javascript
--------------------------------------------------------------------------

                 Key: MYFACES-2745
                 URL: https://issues.apache.org/jira/browse/MYFACES-2745
             Project: MyFaces Core
          Issue Type: Bug
          Components: JSR-314
    Affects Versions: 2.0.1
            Reporter: Michael Concini


The javascript changes from 5/25 have caused a regression when using htmlunit against even
the simplest JSF page as long as it loads the jsf.js script.  

The exception occurs simply executing getPage() on the webClient.
        WebClient webClient = new WebClient();
        HtmlPage page = webClient.getPage("http://localhost:8080/JSF20AJAXTag/DisabledFalse.jsf");


It can be recreated by a page with nothing but this form in the body:
 <h:form id="form1" prependId="false">
        <h:outputText id="out1" value="This is broken"/>
        <h:outputScript name="jsf.js" library="javax.faces" target="head" />
    </h:form>

Attached is the exception trace from a run this morning which includes Werner's changes from
MYFACES-2742 this morning so we are up to date in our sandbox. 
======= EXCEPTION START ========
EcmaError: lineNumber=[51] column=[0] lineSource=[<no source>] name=[TypeError] sourceName=[http://localhost:8080/JSF20AJAXTag/javax.faces.resource/jsf.js.jsf?ln=javax.faces]
message=[TypeError: Cannot set property "_mfProto" of null to "null" (http://localhost:8080/JSF20AJAXTag/javax.faces.resource/jsf.js.jsf?ln=javax.faces#51)]
com.gargoylesoftware.htmlunit.ScriptException: TypeError: Cannot set property "_mfProto" of
null to "null" (http://localhost:8080/JSF20AJAXTag/javax.faces.resource/jsf.js.jsf?ln=javax.faces#51)
	at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine$HtmlUnitContextAction.run(JavaScriptEngine.java:527)
	at net.sourceforge.htmlunit.corejs.javascript.Context.call(Context.java:537)
	at net.sourceforge.htmlunit.corejs.javascript.ContextFactory.call(ContextFactory.java:538)
	at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine.execute(JavaScriptEngine.java:425)
	at com.gargoylesoftware.htmlunit.html.HtmlPage.loadExternalJavaScriptFile(HtmlPage.java:980)
	at com.gargoylesoftware.htmlunit.html.HtmlScript.executeScriptIfNeeded(HtmlScript.java:353)
	at com.gargoylesoftware.htmlunit.html.HtmlScript$1.execute(HtmlScript.java:215)
	at com.gargoylesoftware.htmlunit.html.HtmlScript.onAllChildrenAddedToPage(HtmlScript.java:235)
	at com.gargoylesoftware.htmlunit.html.HTMLParser$HtmlUnitDOMBuilder.endElement(HTMLParser.java:718)
	at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
	at com.gargoylesoftware.htmlunit.html.HTMLParser$HtmlUnitDOMBuilder.endElement(HTMLParser.java:676)
	at org.cyberneko.html.HTMLTagBalancer.callEndElement(HTMLTagBalancer.java:1136)
	at org.cyberneko.html.HTMLTagBalancer.endElement(HTMLTagBalancer.java:1038)
	at org.cyberneko.html.filters.DefaultFilter.endElement(DefaultFilter.java:206)
	at org.cyberneko.html.filters.NamespaceBinder.endElement(NamespaceBinder.java:329)
	at org.cyberneko.html.HTMLScanner$ContentScanner.scanEndElement(HTMLScanner.java:2999)
	at org.cyberneko.html.HTMLScanner$ContentScanner.scan(HTMLScanner.java:1991)
	at org.cyberneko.html.HTMLScanner.scanDocument(HTMLScanner.java:895)
	at org.cyberneko.html.HTMLConfiguration.parse(HTMLConfiguration.java:499)
	at org.cyberneko.html.HTMLConfiguration.parse(HTMLConfiguration.java:452)
	at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
	at com.gargoylesoftware.htmlunit.html.HTMLParser$HtmlUnitDOMBuilder.parse(HTMLParser.java:896)
	at com.gargoylesoftware.htmlunit.html.HTMLParser.parse(HTMLParser.java:350)
	at com.gargoylesoftware.htmlunit.html.HTMLParser.parseHtml(HTMLParser.java:304)
	at com.gargoylesoftware.htmlunit.DefaultPageCreator.createHtmlPage(DefaultPageCreator.java:134)
	at com.gargoylesoftware.htmlunit.DefaultPageCreator.createPage(DefaultPageCreator.java:101)
	at com.gargoylesoftware.htmlunit.WebClient.loadWebResponseInto(WebClient.java:420)
	at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:303)
	at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:360)
	at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:345)
	at com.ibm.mike.TestJS.homePage(TestJS.java:19)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:48)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
	at java.lang.reflect.Method.invoke(Method.java:600)
	at junit.framework.TestCase.runTest(TestCase.java:154)
	at junit.framework.TestCase.runBare(TestCase.java:127)
	at junit.framework.TestResult$1.protect(TestResult.java:106)
	at junit.framework.TestResult.runProtected(TestResult.java:124)
	at junit.framework.TestResult.run(TestResult.java:109)
	at junit.framework.TestCase.run(TestCase.java:118)
	at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
	at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: net.sourceforge.htmlunit.corejs.javascript.EcmaError: TypeError: Cannot set property
"_mfProto" of null to "null" (http://localhost:8080/JSF20AJAXTag/javax.faces.resource/jsf.js.jsf?ln=javax.faces#51)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.constructError(ScriptRuntime.java:3753)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.constructError(ScriptRuntime.java:3731)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.typeError(ScriptRuntime.java:3759)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.typeError3(ScriptRuntime.java:3785)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.undefWriteError(ScriptRuntime.java:3807)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.setObjectElem(ScriptRuntime.java:1578)
	at net.sourceforge.htmlunit.corejs.javascript.Interpreter.interpretLoop(Interpreter.java:1450)
	at net.sourceforge.htmlunit.corejs.javascript.Interpreter.interpret(Interpreter.java:845)
	at net.sourceforge.htmlunit.corejs.javascript.InterpretedFunction.call(InterpretedFunction.java:164)
	at net.sourceforge.htmlunit.corejs.javascript.ContextFactory.doTopCall(ContextFactory.java:429)
	at com.gargoylesoftware.htmlunit.javascript.HtmlUnitContextFactory.doTopCall(HtmlUnitContextFactory.java:264)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3157)
	at net.sourceforge.htmlunit.corejs.javascript.InterpretedFunction.exec(InterpretedFunction.java:175)
	at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine$3.doRun(JavaScriptEngine.java:416)
	at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine$HtmlUnitContextAction.run(JavaScriptEngine.java:521)
	... 46 more
Enclosed exception: 
net.sourceforge.htmlunit.corejs.javascript.EcmaError: TypeError: Cannot set property "_mfProto"
of null to "null" (http://localhost:8080/JSF20AJAXTag/javax.faces.resource/jsf.js.jsf?ln=javax.faces#51)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.constructError(ScriptRuntime.java:3753)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.constructError(ScriptRuntime.java:3731)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.typeError(ScriptRuntime.java:3759)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.typeError3(ScriptRuntime.java:3785)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.undefWriteError(ScriptRuntime.java:3807)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.setObjectElem(ScriptRuntime.java:1578)
	at net.sourceforge.htmlunit.corejs.javascript.Interpreter.interpretLoop(Interpreter.java:1450)
	at script(http://localhost:8080/JSF20AJAXTag/javax.faces.resource/jsf.js.jsf?ln=javax.faces:51)
	at script(http://localhost:8080/JSF20AJAXTag/javax.faces.resource/jsf.js.jsf?ln=javax.faces:48)
	at script(http://localhost:8080/JSF20AJAXTag/javax.faces.resource/jsf.js.jsf?ln=javax.faces:65)
	at net.sourceforge.htmlunit.corejs.javascript.Interpreter.interpret(Interpreter.java:845)
	at net.sourceforge.htmlunit.corejs.javascript.InterpretedFunction.call(InterpretedFunction.java:164)
	at net.sourceforge.htmlunit.corejs.javascript.ContextFactory.doTopCall(ContextFactory.java:429)
	at com.gargoylesoftware.htmlunit.javascript.HtmlUnitContextFactory.doTopCall(HtmlUnitContextFactory.java:264)
	at net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3157)
	at net.sourceforge.htmlunit.corejs.javascript.InterpretedFunction.exec(InterpretedFunction.java:175)
	at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine$3.doRun(JavaScriptEngine.java:416)
	at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine$HtmlUnitContextAction.run(JavaScriptEngine.java:521)
	at net.sourceforge.htmlunit.corejs.javascript.Context.call(Context.java:537)
	at net.sourceforge.htmlunit.corejs.javascript.ContextFactory.call(ContextFactory.java:538)
	at com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine.execute(JavaScriptEngine.java:425)
	at com.gargoylesoftware.htmlunit.html.HtmlPage.loadExternalJavaScriptFile(HtmlPage.java:980)
	at com.gargoylesoftware.htmlunit.html.HtmlScript.executeScriptIfNeeded(HtmlScript.java:353)
	at com.gargoylesoftware.htmlunit.html.HtmlScript$1.execute(HtmlScript.java:215)
	at com.gargoylesoftware.htmlunit.html.HtmlScript.onAllChildrenAddedToPage(HtmlScript.java:235)
	at com.gargoylesoftware.htmlunit.html.HTMLParser$HtmlUnitDOMBuilder.endElement(HTMLParser.java:718)
	at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
	at com.gargoylesoftware.htmlunit.html.HTMLParser$HtmlUnitDOMBuilder.endElement(HTMLParser.java:676)
	at org.cyberneko.html.HTMLTagBalancer.callEndElement(HTMLTagBalancer.java:1136)
	at org.cyberneko.html.HTMLTagBalancer.endElement(HTMLTagBalancer.java:1038)
	at org.cyberneko.html.filters.DefaultFilter.endElement(DefaultFilter.java:206)
	at org.cyberneko.html.filters.NamespaceBinder.endElement(NamespaceBinder.java:329)
	at org.cyberneko.html.HTMLScanner$ContentScanner.scanEndElement(HTMLScanner.java:2999)
	at org.cyberneko.html.HTMLScanner$ContentScanner.scan(HTMLScanner.java:1991)
	at org.cyberneko.html.HTMLScanner.scanDocument(HTMLScanner.java:895)
	at org.cyberneko.html.HTMLConfiguration.parse(HTMLConfiguration.java:499)
	at org.cyberneko.html.HTMLConfiguration.parse(HTMLConfiguration.java:452)
	at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
	at com.gargoylesoftware.htmlunit.html.HTMLParser$HtmlUnitDOMBuilder.parse(HTMLParser.java:896)
	at com.gargoylesoftware.htmlunit.html.HTMLParser.parse(HTMLParser.java:350)
	at com.gargoylesoftware.htmlunit.html.HTMLParser.parseHtml(HTMLParser.java:304)
	at com.gargoylesoftware.htmlunit.DefaultPageCreator.createHtmlPage(DefaultPageCreator.java:134)
	at com.gargoylesoftware.htmlunit.DefaultPageCreator.createPage(DefaultPageCreator.java:101)
	at com.gargoylesoftware.htmlunit.WebClient.loadWebResponseInto(WebClient.java:420)
	at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:303)
	at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:360)
	at com.gargoylesoftware.htmlunit.WebClient.getPage(WebClient.java:345)
	at com.ibm.mike.TestJS.homePage(TestJS.java:19)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:48)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
	at java.lang.reflect.Method.invoke(Method.java:600)
	at junit.framework.TestCase.runTest(TestCase.java:154)
	at junit.framework.TestCase.runBare(TestCase.java:127)
	at junit.framework.TestResult$1.protect(TestResult.java:106)
	at junit.framework.TestResult.runProtected(TestResult.java:124)
	at junit.framework.TestResult.run(TestResult.java:109)
	at junit.framework.TestCase.run(TestCase.java:118)
	at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
	at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
======= EXCEPTION END ========



-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message