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

Perforce NumberFormatException in non-trimmed string

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Component/s: perforce-plugin
    • Labels:
      None
    • Environment:
      Platform: All, OS: All
    • Similar Issues:

      Description

      I copied and pasted a changelist number as being the first to track.
      I didn't notice that I had included a space.
      Perhaps the string should be trimmed of spaces before attempting to convert it
      to an integer value?

      java.lang.NumberFormatException: For input string: "1756317 "
      at java.lang.NumberFormatException.forInputString(Unknown Source)
      at java.lang.Integer.parseInt(Unknown Source)
      at java.lang.Integer.(Unknown Source)
      at
      hudson.plugins.perforce.PerforceSCM$PerforceSCMDescriptor.newInstance(PerforceSCM.java:463)
      at
      hudson.plugins.perforce.PerforceSCM$PerforceSCMDescriptor.newInstance(PerforceSCM.java:438)
      at hudson.model.Descriptor.newInstance(Descriptor.java:176)
      at hudson.scm.SCMS.parseSCM(SCMS.java:38)
      at hudson.model.AbstractProject.submit(AbstractProject.java:1003)
      at hudson.model.Project.submit(Project.java:161)
      at hudson.model.FreeStyleProject.submit(FreeStyleProject.java:68)
      at hudson.model.Job.doConfigSubmit(Job.java:856)
      at hudson.model.AbstractProject.doConfigSubmit(AbstractProject.java:320)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      at java.lang.reflect.Method.invoke(Unknown Source)
      at org.kohsuke.stapler.Function$InstanceFunction.invoke(Function.java:103)
      at org.kohsuke.stapler.Function.bindAndinvoke(Function.java:57)
      at org.kohsuke.stapler.MetaClass$1.doDispatch(MetaClass.java:75)
      at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:30)
      at org.kohsuke.stapler.Stapler.invoke(Stapler.java:409)
      at org.kohsuke.stapler.MetaClass$6.doDispatch(MetaClass.java:173)
      at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:30)
      at org.kohsuke.stapler.Stapler.invoke(Stapler.java:409)
      at org.kohsuke.stapler.Stapler.invoke(Stapler.java:352)
      at org.kohsuke.stapler.Stapler.service(Stapler.java:112)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:45)
      at winstone.ServletConfiguration.execute(ServletConfiguration.java:249)
      at winstone.RequestDispatcher.forward(RequestDispatcher.java:335)
      at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:378)
      at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:61)
      at hudson.util.PluginServletFilter.doFilter(PluginServletFilter.java:53)
      at winstone.FilterConfiguration.execute(FilterConfiguration.java:195)
      at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:368)
      at hudson.security.HudsonFilter.doFilter(HudsonFilter.java:88)
      at winstone.FilterConfiguration.execute(FilterConfiguration.java:195)
      at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:368)
      at winstone.RequestDispatcher.forward(RequestDispatcher.java:333)
      at winstone.RequestHandlerThread.processRequest(RequestHandlerThread.java:244)
      at winstone.RequestHandlerThread.run(RequestHandlerThread.java:150)
      at java.lang.Thread.run(Unknown Source)

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              folkstone42 folkstone42
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: