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

NPE when validating form if configuration contains international characters

    Details

    • Similar Issues:

      Description

      Jenkins 1.406
      Promoted build 2.0
      Publish over SSH 0.9

      Go to a job without any promotion process.

      Click: Configure
      Click: Promote builds when...
      Click: Add action
      Click: Send build artifact over SSH

      500 error:
      java.lang.NullPointerException
      at jenkins.plugins.publish_over_ssh.BapSshPublisherPlugin$Descriptor.doCheckSourceFiles(BapSshPublisherPlugin.java:94)
      at sun.reflect.GeneratedMethodAccessor314.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at org.kohsuke.stapler.Function$InstanceFunction.invoke(Function.java:282)
      at org.kohsuke.stapler.Function.bindAndInvoke(Function.java:149)
      at org.kohsuke.stapler.Function.bindAndInvokeAndServeResponse(Function.java:88)
      at org.kohsuke.stapler.MetaClass$1.doDispatch(MetaClass.java:103)
      at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:53)
      at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:561)
      at org.kohsuke.stapler.Stapler.invoke(Stapler.java:646)
      at org.kohsuke.stapler.MetaClass$6.doDispatch(MetaClass.java:233)
      at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:53)
      at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:561)
      at org.kohsuke.stapler.Stapler.invoke(Stapler.java:646)
      at org.kohsuke.stapler.Stapler.invoke(Stapler.java:477)
      at org.kohsuke.stapler.Stapler.service(Stapler.java:159)
      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:94)
      at hudson.util.PluginServletFilter.doFilter(PluginServletFilter.java:86)
      at winstone.FilterConfiguration.execute(FilterConfiguration.java:195)
      at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:368)
      at hudson.security.csrf.CrumbFilter.doFilter(CrumbFilter.java:47)
      at winstone.FilterConfiguration.execute(FilterConfiguration.java:195)
      at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:368)
      at hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:84)
      at hudson.security.ChainedServletFilter.doFilter(ChainedServletFilter.java:76)
      at hudson.security.HudsonFilter.doFilter(HudsonFilter.java:164)
      at winstone.FilterConfiguration.execute(FilterConfiguration.java:195)
      at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:368)
      at hudson.util.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:81)
      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(Thread.java:662)

      Here "getConfiguration" logically returns null:
      94: if (getConfiguration(configName).isEffectiveDisableExec()) {

      Workaround: first save the promotion process.

        Attachments

          Activity

          Hide
          turb Sylvain Veyrié added a comment - - edited

          I installed 0.10

          As you said, there is no more NPE, but one error:

          "Could not find the SSH Server configuration named [Int�gration Argos]- check the System Configuration and then reload this configuration page" (see capture 2)

          If if throw away the non-ascii char, there is no error.

          There is no error in the Firefox console; only warnings, but in French:

          "Avertissement : La propriété « charCode » d'un événement « keyup » ne doit pas être utilisée. Cette valeur n'a pas de sens.
          Fichier Source : https://issues.jenkins-ci.org/browse/JENKINS-9376?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=147862#comment-147862
          Ligne : 0"

          That can be translated as: "Warning: "charCode" property of a "keyup" event should not be used. This value makes no sense".

          There is no other warnings (but this one again and again).

          I send you my jenkins.plugins.publish_over_ssh.BapSshPublisherPlugin.xml soon.

          Thank you for this quick reaction!

          Show
          turb Sylvain Veyrié added a comment - - edited I installed 0.10 As you said, there is no more NPE, but one error: "Could not find the SSH Server configuration named [Int�gration Argos] - check the System Configuration and then reload this configuration page" (see capture 2) If if throw away the non-ascii char, there is no error. — There is no error in the Firefox console; only warnings, but in French: "Avertissement : La propriété « charCode » d'un événement « keyup » ne doit pas être utilisée. Cette valeur n'a pas de sens. Fichier Source : https://issues.jenkins-ci.org/browse/JENKINS-9376?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=147862#comment-147862 Ligne : 0" That can be translated as: "Warning: "charCode" property of a "keyup" event should not be used. This value makes no sense". There is no other warnings (but this one again and again). I send you my jenkins.plugins.publish_over_ssh.BapSshPublisherPlugin.xml soon. Thank you for this quick reaction!
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: bap2000
          Path:
          src/main/webapp/js/pos.js
          http://jenkins-ci.org/commit/publish-over-ssh-plugin/debc24f899188fd247e14aec7d4b915eebc0f7ac
          Log:
          [FIXED JENKINS-9376] ajax form validation with international characters in configuration name

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: bap2000 Path: src/main/webapp/js/pos.js http://jenkins-ci.org/commit/publish-over-ssh-plugin/debc24f899188fd247e14aec7d4b915eebc0f7ac Log: [FIXED JENKINS-9376] ajax form validation with international characters in configuration name
          Hide
          bap bap added a comment -

          Fixed in 0.11

          Show
          bap bap added a comment - Fixed in 0.11
          Hide
          bap bap added a comment -

          Thank you so much!

          Try 0.11 I think you will find it is fixed.
          Can you report back so I can close the issue - or if it is not fixed then I will have another look.

          The problem was only with the form validation, the plugin would have worked when run - it was just that it didn't look like it

          Show
          bap bap added a comment - Thank you so much! Try 0.11 I think you will find it is fixed. Can you report back so I can close the issue - or if it is not fixed then I will have another look. The problem was only with the form validation, the plugin would have worked when run - it was just that it didn't look like it
          Hide
          turb Sylvain Veyrié added a comment -

          Solved in 0.11 (checked).

          Thank you very much!

          Show
          turb Sylvain Veyrié added a comment - Solved in 0.11 (checked). Thank you very much!

            People

            • Assignee:
              bap bap
              Reporter:
              turb Sylvain Veyrié
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: