[JIRA] (JENKINS-62077) findFiles fails when executed in empty workspace

0 views
Skip to first unread message

Christopher.Fenner@me.com (JIRA)

unread,
Apr 28, 2020, 4:32:02 AM4/28/20
to jenkinsc...@googlegroups.com
Christopher Fenner created an issue
 
Jenkins / Bug JENKINS-62077
findFiles fails when executed in empty workspace
Issue Type: Bug Bug
Assignee: rsandell
Components: pipeline-utility-steps-plugin
Created: 2020-04-28 08:31
Environment: Jenkins: 2.204.2
pipeline-utility-steps-plugin: 2.5.0
Priority: Minor Minor
Reporter: Christopher Fenner

When executing `findFiles` with a glob pattern on an empty workspace, a `java.io.IOException` is raised stating that the workspace is not found.

 

Pipeline script to reproduce

 

node{
  deleteDir()
  findFiles(glob: 'test')
}

Exception:

 

java.io.IOException: /var/jenkins_home/workspace/Test/FindFiles does not exist.
	at hudson.FilePath.glob(FilePath.java:1932)
	at hudson.FilePath.access$3200(FilePath.java:211)
	at hudson.FilePath$ListGlob.invoke(FilePath.java:1906)
	at hudson.FilePath$ListGlob.invoke(FilePath.java:1894)
	at hudson.FilePath.act(FilePath.java:1075)
	at hudson.FilePath.act(FilePath.java:1058)
	at hudson.FilePath.list(FilePath.java:1892)
	at hudson.FilePath.list(FilePath.java:1876)
	at org.jenkinsci.plugins.pipeline.utility.steps.fs.FindFilesStepExecution.run(FindFilesStepExecution.java:63)
	at org.jenkinsci.plugins.pipeline.utility.steps.fs.FindFilesStepExecution.run(FindFilesStepExecution.java:44)
	at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.13.12#713012-sha1:6e07c38)
Atlassian logo

Christopher.Fenner@me.com (JIRA)

unread,
Apr 28, 2020, 6:59:02 AM4/28/20
to jenkinsc...@googlegroups.com
Christopher Fenner updated an issue
Change By: Christopher Fenner
When executing `findFiles` with a glob pattern on an empty workspace, a `java.io.IOException` is raised stating that the workspace is not found.

 

Pipeline script to reproduce

 
{code:java}

node{
  deleteDir()
  findFiles(glob: 'test')
}
{code}
Exception:  

Exception:  
{code:java}

java.io.IOException: /var/jenkins_home/workspace/Test/FindFiles does not exist.
at hudson.FilePath.glob(FilePath.java:1932)
at hudson.FilePath.access$3200(FilePath.java:211)
at hudson.FilePath$ListGlob.invoke(FilePath.java:1906)
at hudson.FilePath$ListGlob.invoke(FilePath.java:1894)
at hudson.FilePath.act(FilePath.java:1075)
at hudson.FilePath.act(FilePath.java:1058)
at hudson.FilePath.list(FilePath.java:1892)
at hudson.FilePath.list(FilePath.java:1876)
at org.jenkinsci.plugins.pipeline.utility.steps.fs.FindFilesStepExecution.run(FindFilesStepExecution.java:63)
at org.jenkinsci.plugins.pipeline.utility.steps.fs.FindFilesStepExecution.run(FindFilesStepExecution.java:44)
at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
{code}
Reply all
Reply to author
Forward
0 new messages