-
Notifications
You must be signed in to change notification settings - Fork 102
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NullPointerException thrown due to Mojarra 2.3 PartialViewContextImpl inspecting InternalIE8CompatiblityLinks as a resource #831
Comments
I've managed to reproduce the bug, sort of, that is. Mojarra adds an additional null-check, so there's no NPE in Mojarra. But I was using the Liferay Faces bridge, the NPE would be thrown as you describe. BTW, thanks for your excellent description and analysis! I suggest we tackle the problem on both fronts:
|
@ngriffin7a When I set the name, the CombinedResourceListener of OmniFaces seems to expect that the file exists. So I could add a dummy file. But that seems to be a bit odd to me. I suggest you add an extra null check in your code. BTW, it's funny that our |
@stephanrauh Dummy resources are sometimes done in JSF resource libraries. For example: |
@stephanrauh Maybe the Mojarra |
Fixed in the bridge https://issues.liferay.com/browse/FACES-3168 Feel free to close this issue if you don't want to make any changes to BootsFaces. Thans @stephanrauh ! :) |
Your welcome! Yes, that was the method I was referring to. |
Using a dummy resource doesn't work well with the CombinedResourceHandler of OmniFaces. It takes the dummy resource, puts it into the combined JavaScript file and deletes our resource. So our resource can't render itself. Hence I close the ticket without modifying anything. |
OK thanks for the effort. :) |
Although this issue was first encountered with the FacesBridge for Portlet 3.0 + JSF 2.3 using Mojarra 2.3, at this time I don't think it is related to Portlet 3.0. In other words, it should be possible to reproduce this in a plain BootsFaces webapp that uses f:ajax in order to handle
onchange
inside of a text field.According to the stacktrace below,
PartialViewContextImpl.renderComponentResources(renderComponentResources(FacesContext context, UIViewRoot viewRoot)
is trying to execute the following loop:And when the
resource
variable is an instance of InternalIE8CompatiblityLinks.java, the value of name and library are both equal tonull
. Because of this, the call toresourceHandler.getRendererTypeForResourceName(name)
throws aNullPointerException
further up the stack.The text was updated successfully, but these errors were encountered: