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

"groovy.lang.MissingPropertyException Exception evaluating property 'size' for java.util.ArrayList" when using IBM Java 6

      When using IBM Java 6, the following error happens when trying to see a build result.

      The bug seems to be the following line in hudson.plugins.parameterizedtrigger.BuildInfoExporterAction.sumary.groovy: if (projects.size > 0) {

      This is related to this: http://jira.codehaus.org/browse/GROOVY-4094 , where it is mentioned that should be size(), not size.

      Stack trace:
      Caused by: groovy.lang.MissingPropertyException: Exception evaluating property 'size' for java.util.ArrayList, Reason: groovy.lang.MissingPropertyException: No such property: size for class: hudson.model.FreeStyleProject
      Possible solutions: name, scm
      at org.codehaus.groovy.runtime.DefaultGroovyMethods.getAt(DefaultGroovyMethods.java:6810)
      at groovy.lang.MetaClassImpl$7.getProperty(MetaClassImpl.java:1712)
      at org.codehaus.groovy.runtime.callsite.GetEffectivePojoPropertySite.getProperty(GetEffectivePojoPropertySite.java:61)
      at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callGetProperty(AbstractCallSite.java:227)
      at hudson.plugins.parameterizedtrigger.BuildInfoExporterAction.summary.run(summary.groovy:30)
      at org.kohsuke.stapler.jelly.groovy.GroovierJellyScript.run(GroovierJellyScript.java:69)
      at org.kohsuke.stapler.jelly.groovy.GroovierJellyScript.run(GroovierJellyScript.java:62)
      at org.kohsuke.stapler.jelly.IncludeTag.doTag(IncludeTag.java:146)
      at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:269)
      ... 96 more

          [JENKINS-20719] "groovy.lang.MissingPropertyException Exception evaluating property 'size' for java.util.ArrayList" when using IBM Java 6

          ikedam added a comment -

          Thanks for the detail. It helps me a lot to fix the problem.

          ikedam added a comment - Thanks for the detail. It helps me a lot to fix the problem.

          Code changed in jenkins
          User: ikedam
          Path:
          src/main/resources/hudson/plugins/parameterizedtrigger/BuildInfoExporterAction/summary.groovy
          http://jenkins-ci.org/commit/parameterized-trigger-plugin/b0e531f728d60f6cc89939dc6c35f1456c145ba2
          Log:
          [FIXED JENKINS-20719] Fixed projects.size to projects.size() in groovy script. This caused exception with IBM Java 6.

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: ikedam Path: src/main/resources/hudson/plugins/parameterizedtrigger/BuildInfoExporterAction/summary.groovy http://jenkins-ci.org/commit/parameterized-trigger-plugin/b0e531f728d60f6cc89939dc6c35f1456c145ba2 Log: [FIXED JENKINS-20719] Fixed projects.size to projects.size() in groovy script. This caused exception with IBM Java 6.

          ikedam added a comment -

          Fixed in 2.22.

          ikedam added a comment - Fixed in 2.22.

            ikedam ikedam
            gabriel Gabriel Lopez
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: