-
Bug
-
Resolution: Unresolved
-
Minor
-
None
-
Jenkins: 2.204.2
pipeline-utility-steps-plugin: 2.5.0
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)