[JIRA] (JENKINS-59425) When specifying an invalid script path the build fails with an hard-to-read exception

7 views
Skip to first unread message

vincent@latombe.net (JIRA)

unread,
Sep 18, 2019, 4:42:04 AM9/18/19
to jenkinsc...@googlegroups.com
Vincent Latombe created an issue
 
Jenkins / Bug JENKINS-59425
When specifying an invalid script path the build fails with an hard-to-read exception
Issue Type: Bug Bug
Assignee: Unassigned
Components: workflow-cps-plugin
Created: 2019-09-18 08:41
Priority: Minor Minor
Reporter: Vincent Latombe

Using a pipeline from SCM that is targetting a file that doesn't exist, the build fails immediately with the following exception.

 java.io.FileNotFoundException
 	at jenkins.plugins.git.GitSCMFile$3.invoke(GitSCMFile.java:173)
 	at jenkins.plugins.git.GitSCMFile$3.invoke(GitSCMFile.java:165)
 	at jenkins.plugins.git.GitSCMFileSystem$3.invoke(GitSCMFileSystem.java:195)
 	at org.jenkinsci.plugins.gitclient.AbstractGitAPIImpl.withRepository(AbstractGitAPIImpl.java:29)
 	at org.jenkinsci.plugins.gitclient.CliGitAPIImpl.withRepository(CliGitAPIImpl.java:72)
 	at jenkins.plugins.git.GitSCMFileSystem.invoke(GitSCMFileSystem.java:191)
 	at jenkins.plugins.git.GitSCMFile.content(GitSCMFile.java:165)
 	at jenkins.scm.api.SCMFile.contentAsString(SCMFile.java:335)
 	at org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:115)
 	at org.jenkinsci.plugins.workflow.cps.CpsScmFlowDefinition.create(CpsScmFlowDefinition.java:67)
 	at org.jenkinsci.plugins.workflow.job.WorkflowRun.run(WorkflowRun.java:293)
 	at hudson.model.ResourceController.execute(ResourceController.java:97)
 	at hudson.model.Executor.run(Executor.java:429)
 Finished: FAILURE

It would be much friendlier to print some valuable information in that case like "Unable to find yourinvalidfile from git https://github.com/yourorg/yourrepo"

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo

vincent@latombe.net (JIRA)

unread,
Sep 18, 2019, 4:42:06 AM9/18/19
to jenkinsc...@googlegroups.com
Vincent Latombe started work on Bug JENKINS-59425
 
Change By: Vincent Latombe
Status: Open In Progress

vincent@latombe.net (JIRA)

unread,
Sep 18, 2019, 4:42:06 AM9/18/19
to jenkinsc...@googlegroups.com

vincent@latombe.net (JIRA)

unread,
Sep 18, 2019, 4:44:02 AM9/18/19
to jenkinsc...@googlegroups.com

dnusbaum@cloudbees.com (JIRA)

unread,
Oct 31, 2019, 4:41:03 PM10/31/19
to jenkinsc...@googlegroups.com
Devin Nusbaum updated Bug JENKINS-59425
 

A fix for this issue was just released in Pipeline: Groovy Plugin version 2.75.

Change By: Devin Nusbaum
Status: In Review Resolved
Resolution: Fixed
Released As: workflow-cps 2.75
Reply all
Reply to author
Forward
0 new messages