Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-13781

NPE in UserRelevanceView when no user is logged on

    Details

    • Similar Issues:

      Description

      I'm getting a NPE when i try to use the view-job-filters plugin with a recent Jenkins install (did try with 1463,1464):

      /.jenkins/war/WEB-INF/lib/jenkins-core-1.464.jar!/lib/hudson/projectView.jelly:60:22: <d:invokeBody> java.lang.NullPointerException
      at org.apache.commons.jelly.impl.TagScript.handleException(TagScript.java:716)
      at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:282)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.kohsuke.stapler.jelly.CallTagLibScript$1.run(CallTagLibScript.java:98)
      at org.apache.commons.jelly.tags.define.InvokeBodyTag.doTag(InvokeBodyTag.java:91)
      at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:270)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.apache.commons.jelly.tags.core.CoreTagLibrary$1.run(CoreTagLibrary.java:98)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.apache.commons.jelly.tags.core.CoreTagLibrary$2.run(CoreTagLibrary.java:105)
      at org.kohsuke.stapler.jelly.CallTagLibScript.run(CallTagLibScript.java:119)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.kohsuke.stapler.jelly.CallTagLibScript$1.run(CallTagLibScript.java:98)
      at org.apache.commons.jelly.tags.define.InvokeBodyTag.doTag(InvokeBodyTag.java:91)
      at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:270)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.kohsuke.stapler.jelly.ReallyStaticTagLibrary$1.run(ReallyStaticTagLibrary.java:99)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.kohsuke.stapler.jelly.ReallyStaticTagLibrary$1.run(ReallyStaticTagLibrary.java:99)
      at org.kohsuke.stapler.jelly.ReallyStaticTagLibrary$1.run(ReallyStaticTagLibrary.java:99)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.kohsuke.stapler.jelly.ReallyStaticTagLibrary$1.run(ReallyStaticTagLibrary.java:99)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.kohsuke.stapler.jelly.ReallyStaticTagLibrary$1.run(ReallyStaticTagLibrary.java:99)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.apache.commons.jelly.tags.core.CoreTagLibrary$2.run(CoreTagLibrary.java:105)
      at org.kohsuke.stapler.jelly.CallTagLibScript.run(CallTagLibScript.java:119)
      at org.kohsuke.stapler.jelly.CompressTag.doTag(CompressTag.java:44)
      at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:270)
      at org.kohsuke.stapler.jelly.JellyViewScript.run(JellyViewScript.java:81)
      at org.kohsuke.stapler.jelly.DefaultScriptInvoker.invokeScript(DefaultScriptInvoker.java:63)
      at org.kohsuke.stapler.jelly.DefaultScriptInvoker.invokeScript(DefaultScriptInvoker.java:53)
      at org.kohsuke.stapler.jelly.JellyClassTearOff.serveIndexJelly(JellyClassTearOff.java:107)
      ... 53 more
      Caused by: java.lang.RuntimeException: org.apache.commons.jelly.JellyTagException: jar:file://.jenkins/war/WEB-INF/lib/jenkins-core-1.464.jar!/lib/hudson/projectView.jelly:60:22: <d:invokeBody> java.lang.NullPointerException
      at org.kohsuke.stapler.jelly.groovy.JellyBuilder.doInvokeMethod(JellyBuilder.java:287)
      at org.kohsuke.stapler.jelly.groovy.Namespace$ProxyImpl.invoke(Namespace.java:92)
      at $Proxy25.projectView(Unknown Source)
      at lib.JenkinsTagLib$projectView.call(Unknown Source)
      at hudson.model.View.main.run(main.groovy:14)
      at org.kohsuke.stapler.jelly.groovy.GroovierJellyScript.run(GroovierJellyScript.java:66)
      at org.kohsuke.stapler.jelly.groovy.GroovierJellyScript.run(GroovierJellyScript.java:59)
      at org.kohsuke.stapler.jelly.IncludeTag.doTag(IncludeTag.java:146)
      at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:270)
      ... 84 more
      Caused by: org.apache.commons.jelly.JellyTagException: jar:file://.jenkins/war/WEB-INF/lib/jenkins-core-1.464.jar!/lib/hudson/projectView.jelly:60:22: <d:invokeBody> java.lang.NullPointerException
      at org.apache.commons.jelly.impl.TagScript.handleException(TagScript.java:716)
      at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:282)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.apache.commons.jelly.tags.core.CoreTagLibrary$1.run(CoreTagLibrary.java:98)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.kohsuke.stapler.jelly.ReallyStaticTagLibrary$1.run(ReallyStaticTagLibrary.java:99)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.apache.commons.jelly.tags.core.CoreTagLibrary$2.run(CoreTagLibrary.java:105)
      at org.kohsuke.stapler.jelly.CallTagLibScript.run(CallTagLibScript.java:119)
      at org.kohsuke.stapler.jelly.groovy.JellyBuilder.doInvokeMethod(JellyBuilder.java:283)
      ... 92 more
      Caused by: java.lang.NullPointerException
      at hudson.views.UserRelevanceFilter.matchesEmail(UserRelevanceFilter.java:143)
      at hudson.views.UserRelevanceFilter.matches(UserRelevanceFilter.java:64)
      at hudson.views.AbstractIncludeExcludeJobFilter.doFilter(AbstractIncludeExcludeJobFilter.java:68)
      at hudson.views.AbstractIncludeExcludeJobFilter.filter(AbstractIncludeExcludeJobFilter.java:57)
      at hudson.model.ListView.getItems(ListView.java:162)
      at hudson.model.ListView.getItems(ListView.java:58)
      at hudson.security.AuthorizationStrategy$1.hasPermission(AuthorizationStrategy.java:103)
      at hudson.security.ACL.hasPermission(ACL.java:65)
      at hudson.model.View.hasPermission(View.java:503)
      at hudson.model.ViewGroupMixIn.getViews(ViewGroupMixIn.java:115)
      at jenkins.model.Jenkins.getViews(Jenkins.java:1369)
      at sun.reflect.GeneratedMethodAccessor164.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      at java.lang.reflect.Method.invoke(Unknown Source)
      at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90)
      at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:233)
      at groovy.lang.MetaClassImpl$GetBeanMethodMetaProperty.getProperty(MetaClassImpl.java:3457)
      at org.codehaus.groovy.runtime.callsite.GetEffectivePojoPropertySite.getProperty(GetEffectivePojoPropertySite.java:61)
      at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callGetProperty(AbstractCallSite.java:227)
      at hudson.model.View.main$_run_closure1.doCall(main.groovy:15)
      at sun.reflect.GeneratedMethodAccessor162.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      at java.lang.reflect.Method.invoke(Unknown Source)
      at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90)
      at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:233)
      at org.codehaus.groovy.runtime.metaclass.ClosureMetaClass.invokeMethod(ClosureMetaClass.java:272)
      at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:884)
      at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.callCurrent(PogoMetaClassSite.java:66)
      at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:141)
      at hudson.model.View.main$_run_closure1.doCall(main.groovy)
      at sun.reflect.GeneratedMethodAccessor161.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      at java.lang.reflect.Method.invoke(Unknown Source)
      at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90)
      at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:233)
      at org.codehaus.groovy.runtime.metaclass.ClosureMetaClass.invokeMethod(ClosureMetaClass.java:272)
      at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:884)
      at groovy.lang.Closure.call(Closure.java:412)
      at groovy.lang.Closure.call(Closure.java:406)
      at org.kohsuke.stapler.jelly.groovy.JellyBuilder$1.run(JellyBuilder.java:271)
      at org.kohsuke.stapler.jelly.CallTagLibScript$1.run(CallTagLibScript.java:98)
      at org.apache.commons.jelly.tags.define.InvokeBodyTag.doTag(InvokeBodyTag.java:91)
      at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:270)
      ... 100 more

      This only happens when i select "logged in users can do anything", when i disable access controll, everything seems to work fine.

      The bad thing is, the error message triggered from this bug seem to cause our jenkins server to incorrectly encode the response, it is only visible if i set "network.http.accept-encoding" to "none" in firefox.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                jacob_robertson Jacob Robertson
                Reporter:
                mglauche Michael Glauche
              • Votes:
                1 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: