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

Error in Jenkinsfile causes infinite build loop with polling trigger

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open (View Workflow)
    • Priority: Major
    • Resolution: Unresolved
    • Component/s: pollscm-plugin
    • Labels:
      None
    • Environment:
      AWS ECS
      Jenkins v2.150.3
      BlueOcean v1.16.0
      All plugins up-to-date
    • Similar Issues:

      Description

      I had an error in my Jenkinsfile today were I was missing a closing bracket, causing my builds to fail and a new build triggered for the same commit every 2 minutes which I suspect is due to a poll trigger in the pipeline configuration

      triggers { 
         // poll repo every 2 minute for changinges 
         pollSCM('*/2 * * * *') 
      }
      

       the pipeline logs were

      Started by an SCM change
      Obtained Jenkinsfile from 7c608f6019a2de1e1db0fd32ffa48fc915be13c7
      Running in Durability level: PERFORMANCE_OPTIMIZED
      [Bitbucket] Notifying commit build result
      [Bitbucket] Build result notified
      org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed:
      WorkflowScript: 974: expecting '}', found '' @ line 974, column 1.
      1 error
      
      	at org.codehaus.groovy.control.ErrorCollector.failIfErrors(ErrorCollector.java:310)
      	at org.codehaus.groovy.control.ErrorCollector.addFatalError(ErrorCollector.java:150)
      	at org.codehaus.groovy.control.ErrorCollector.addError(ErrorCollector.java:120)
      	at org.codehaus.groovy.control.ErrorCollector.addError(ErrorCollector.java:132)
      	at org.codehaus.groovy.control.SourceUnit.addError(SourceUnit.java:350)
      	at org.codehaus.groovy.antlr.AntlrParserPlugin.transformCSTIntoAST(AntlrParserPlugin.java:144)
      	at org.codehaus.groovy.antlr.AntlrParserPlugin.parseCST(AntlrParserPlugin.java:110)
      	at org.codehaus.groovy.control.SourceUnit.parse(SourceUnit.java:234)
      	at org.codehaus.groovy.control.CompilationUnit$1.call(CompilationUnit.java:168)
      	at org.codehaus.groovy.control.CompilationUnit.applyToSourceUnits(CompilationUnit.java:943)
      	at org.codehaus.groovy.control.CompilationUnit.doPhaseOperation(CompilationUnit.java:605)
      	at org.codehaus.groovy.control.CompilationUnit.processPhaseOperations(CompilationUnit.java:581)
      	at org.codehaus.groovy.control.CompilationUnit.compile(CompilationUnit.java:558)
      	at groovy.lang.GroovyClassLoader.doParseClass(GroovyClassLoader.java:298)
      	at groovy.lang.GroovyClassLoader.parseClass(GroovyClassLoader.java:268)
      	at groovy.lang.GroovyShell.parseClass(GroovyShell.java:688)
      	at groovy.lang.GroovyShell.parse(GroovyShell.java:700)
      	at org.jenkinsci.plugins.workflow.cps.CpsGroovyShell.doParse(CpsGroovyShell.java:133)
      	at org.jenkinsci.plugins.workflow.cps.CpsGroovyShell.reparse(CpsGroovyShell.java:126)
      	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.parseScript(CpsFlowExecution.java:561)
      	at org.jenkinsci.plugins.workflow.cps.CpsFlowExecution.start(CpsFlowExecution.java:522)
      	at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:320)
      	at hudson.model.ResourceController.execute(ResourceController.java:97)
      	at hudson.model.Executor.run(Executor.java:429)
      Finished: FAILURE
      

       

       

        Attachments

          Activity

          There are no comments yet on this issue.

            People

            Assignee:
            vlatombe Vincent Latombe
            Reporter:
            jonathank Jonathan Kuleff
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated: