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

Allow InputStep.id to start with a lowercase letter

      As per this change, the id of an input step must start with a capital letter. Fine enough for computed IDs, but very confusing for an explicitly specified ID.

      The reasoning was so that getDynamic would not be ambiguous. But I think this would be fixed more easily by deprecating getDynamic, using getExecution, and making this code append execution/ to the base URL.

          [JENKINS-34509] Allow InputStep.id to start with a lowercase letter

          C Flamm added a comment -

          Currently (v2.36) it's possible to define an input with a lower case id, but if you later want to provide the input via Rest you have to spell the id with a capital first letter.

          ...
              stage ('main') {
                  input(id: 'foofoo', message: 'Moo?')
              }
          ...
          

          id used as defined doesn't work.

          $ curl -X POST http://localhost:8080/job/pipe1/16/input/foofoo/proceedEmpty
          <html>
          <head>
          <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
          <title>Error 404 Not Found</title>
          </head>
          <body><h2>HTTP ERROR 404</h2>
          <p>Problem accessing /job/pipe1/16/input/foofoo/proceedEmpty. Reason:
          <pre>    Not Found</pre></p><hr><i><small>Powered by Jetty://</small></i><hr/>
          
          </body>
          </html>
          

          Capitalized id works fine.

          $ curl -X POST http://localhost:8080/job/pipe1/16/input/Foofoo/proceedEmpty
          

          C Flamm added a comment - Currently (v2.36) it's possible to define an input with a lower case id , but if you later want to provide the input via Rest you have to spell the id with a capital first letter. ... stage ('main') { input(id: 'foofoo', message: 'Moo?') } ... id used as defined doesn't work. $ curl -X POST http://localhost:8080/job/pipe1/16/input/foofoo/proceedEmpty <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <title>Error 404 Not Found</title> </head> <body><h2>HTTP ERROR 404</h2> <p>Problem accessing /job/pipe1/16/input/foofoo/proceedEmpty. Reason: <pre> Not Found</pre></p><hr><i><small>Powered by Jetty://</small></i><hr/> </body> </html> Capitalized id works fine. $ curl -X POST http://localhost:8080/job/pipe1/16/input/Foofoo/proceedEmpty

            jglick Jesse Glick
            jglick Jesse Glick
            Votes:
            2 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated: