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

Error handling: missing Jenkinsfile results in blank screen instead of sensible error

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • workflow-cps-plugin
    • None

      When jenkins is pointed at a repo where a Jenkinsfile is expected, but is missing, we get a blank build screen.

      Ideally we should get a clean error message telling us that Jenkinsfile is missing.

      When we go hunting for errors we find the following ugly exception.

      org.tmatesoft.svn.core.SVNException: svn: E160013: '/svn/redwax/rst/!svn/bc/88/redwax-signtext/trunk/Jenkinsfile' path not found: 404 Not Found (https://source.redwax.eu)
      	at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:70)
      	at org.tmatesoft.svn.core.internal.wc.SVNErrorManager.error(SVNErrorManager.java:57)
      	at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:811)
      	at org.tmatesoft.svn.core.internal.io.dav.http.HTTPConnection.request(HTTPConnection.java:403)
      	at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.performHttpRequest(DAVConnection.java:924)
      	at org.tmatesoft.svn.core.internal.io.dav.DAVConnection.doGet(DAVConnection.java:336)
      	at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.getFile(DAVRepository.java:301)
      	at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.getFile(DAVRepository.java:263)
      	at jenkins.scm.impl.subversion.SubversionSCMFile.content(SubversionSCMFile.java:82)
      Caused: java.io.IOException: failed to fetch file: Jenkinsfile
      	at jenkins.scm.impl.subversion.SubversionSCMFile.content(SubversionSCMFile.java:85)
      	at jenkins.scm.api.SCMFile.contentAsString(SCMFile.java:335)
      	at org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:127)
      	at org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:71)
      	at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:311)
      	at hudson.model.ResourceController.execute(ResourceController.java:101)
      	at hudson.model.Executor.run(Executor.java:442)
      Finished: FAILURE
      

            Unassigned Unassigned
            minfrin Graham Leggett
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: