-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
Powered by SuggestiMate
Found in 3.0.4, downgrading to version 3.0.1 makes it work again.
in the jenkins log:
java.io.FileNotFoundException: /var/lib/jenkins/jobs/musicTreePrograms-master/builds/53/jacoco/sources/nl/pelagic/audio/conversion/flac2mp3/FlacToMp3Impl.java (No such file or directory)
while it should have been looking in
/var/lib/jenkins/jobs/musicTreePrograms-master/builds/53/jacoco/sources/src/nl/pelagic/audio/conversion/flac2mp3/FlacToMp3Impl.java
(note the extra 'src/' afters 'sources')
[JENKINS-55996] jacoco: Error while reading the sourcefile!
fhuberts I found that if you append a '/' to the end you get the sources back. however you do see this warning in the logs:
[JaCoCo plugin] WARNING: You are using directory patterns with trailing /, /* or /** . This will most likely multiply the copied files in your build directory. Check the list below and ignore this warning if you know what you are doing.
We ran into similar looking errors with 2 multi-module projects when upgrading from 3.0.1 to 3.0.4. Also resolved by reverting to 3.0.1
1st example
[JaCoCo plugin] - /jenkins/workspace/revenueCycleApiService-trunk/278/src/main/java 382 filesERROR: Step ‘Record JaCoCo coverage report’ aborted due to exception: [JaCoCo plugin] - /jenkins/workspace/revenueCycleApiService-trunk/278/src/main/java 382 filesERROR: Step ‘Record JaCoCo coverage report’ aborted due to exception: java.nio.file.AccessDeniedException: /jenkins/jobs/revenueCycleApiService-trunk/builds/11/jacoco/sources/java/com/.svn/entries at sun.nio.fs.UnixException.translateToIOException(UnixException.java:84) at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102) at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107) at sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:214) at java.nio.file.spi.FileSystemProvider.newOutputStream(FileSystemProvider.java:434) at java.nio.file.Files.newOutputStream(Files.java:216) at hudson.util.IOUtils.copy(IOUtils.java:42) at hudson.FilePath.readFromTar(FilePath.java:2579) Also: Also: hudson.remoting.Channel$CallSiteStackTrace: Remote call to dapajenkin101 at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1743) at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:357) at hudson.remoting.Channel$2.adapt(Channel.java:992) at hudson.remoting.Channel$2.adapt(Channel.java:988) at hudson.remoting.FutureAdapter.get(FutureAdapter.java:59) at hudson.FilePath.copyRecursiveTo(FilePath.java:2377) at hudson.FilePath.copyRecursiveTo(FilePath.java:2339) at hudson.plugins.jacoco.JacocoReportDir.saveSourcesFrom(JacocoReportDir.java:48) at hudson.plugins.jacoco.JacocoPublisher.perform(JacocoPublisher.java:635) at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690) at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.post2(MavenModuleSetBuild.java:1074) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635) at hudson.model.Run.execute(Run.java:1843) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:543) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429) java.io.IOException: This archives contains unclosed entries. at org.apache.commons.compress.archivers.tar.TarArchiveOutputStream.finish(TarArchiveOutputStream.java:225) at org.apache.commons.compress.archivers.tar.TarArchiveOutputStream.close(TarArchiveOutputStream.java:241) at hudson.util.io.TarArchiver.close(TarArchiver.java:126) at hudson.FilePath.writeToTar(FilePath.java:2549) at hudson.FilePath.access$4000(FilePath.java:212) at hudson.FilePath$CopyRecursiveRemoteToLocal.invoke(FilePath.java:2512) at hudson.FilePath$CopyRecursiveRemoteToLocal.invoke(FilePath.java:2501) at hudson.FilePath$FileCallableWrapper.call(FilePath.java:3050) at hudson.remoting.UserRequest.perform(UserRequest.java:212) at hudson.remoting.UserRequest.perform(UserRequest.java:54) at hudson.remoting.Request$2.run(Request.java:369) at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused: java.util.concurrent.ExecutionException at hudson.remoting.Channel$2.adapt(Channel.java:994) at hudson.remoting.Channel$2.adapt(Channel.java:988) at hudson.remoting.FutureAdapter.get(FutureAdapter.java:59) at hudson.FilePath.copyRecursiveTo(FilePath.java:2377) Caused: java.io.IOException: Failed to extract /jenkins/workspace/revenueCycleApiService-trunk/api/src/main/java/null at hudson.FilePath.readFromTar(FilePath.java:2589) at hudson.FilePath.copyRecursiveTo(FilePath.java:2374) at hudson.FilePath.copyRecursiveTo(FilePath.java:2339) at hudson.plugins.jacoco.JacocoReportDir.saveSourcesFrom(JacocoReportDir.java:48) at hudson.plugins.jacoco.JacocoPublisher.perform(JacocoPublisher.java:635) at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690) at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.post2(MavenModuleSetBuild.java:1074) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635) at hudson.model.Run.execute(Run.java:1843) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:543) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429)
2nd example
/jenkins/workspace/actions-trunk/actions-api/src/main/java 462 filesERROR: Step ‘Record JaCoCo coverage report’ aborted due to exception: /jenkins/workspace/actions-trunk/actions-api/src/main/java 462 filesERROR: Step ‘Record JaCoCo coverage report’ aborted due to exception: 2019-09-13 21:30:38.691 java.nio.file.AccessDeniedException: /jenkins/jobs/actions-trunk/builds/12/jacoco/sources/java/.svn/entries at sun.nio.fs.UnixException.translateToIOException(UnixException.java:84) at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:102) at sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:107) at sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:214) at java.nio.file.spi.FileSystemProvider.newOutputStream(FileSystemProvider.java:434) at java.nio.file.Files.newOutputStream(Files.java:216) at hudson.util.IOUtils.copy(IOUtils.java:42) at hudson.FilePath.readFromTar(FilePath.java:2579) Caused: java.io.IOException: Failed to extract /jenkins/workspace/actions-trunk/actions-auth/src/main/java/null at hudson.FilePath.readFromTar(FilePath.java:2589) at hudson.FilePath.copyRecursiveTo(FilePath.java:2374) at hudson.FilePath.copyRecursiveTo(FilePath.java:2339) at hudson.plugins.jacoco.JacocoReportDir.saveSourcesFrom(JacocoReportDir.java:48) at hudson.plugins.jacoco.JacocoPublisher.perform(JacocoPublisher.java:635) at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:79) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:741) at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690) at hudson.maven.MavenModuleSetBuild$MavenModuleSetBuildExecution.post2(MavenModuleSetBuild.java:1074) at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635) at hudson.model.Run.execute(Run.java:1843) at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:543) at hudson.model.ResourceController.execute(ResourceController.java:97) at hudson.model.Executor.run(Executor.java:429)
Please provide the full output from the JaCoCo publisher to show the actual configuration and other related outpus
I attached the jenkins job console output for the first example ("JENKINS-55996.out"). Here is the plugin config the job used:
<plugin> <groupId>org.jacoco</groupId> <artifactId>jacoco-maven-plugin</artifactId> <version>0.7.9</version> <executions> <execution> <id>prepare-agent</id> <goals> <goal>prepare-agent</goal> </goals> </execution> <execution> <id>report</id> <phase>test</phase> <goals> <goal>report</goal> </goals> </execution> </executions> </plugin>
The error-message in the attached logs is different: "AccessDeniedException: /jenkins/jobs/revenueCycleApiService-trunk/builds/11/jacoco/sources/java/com/.svn/entries", maybe this is unrelated? Did some other user write to the directory before?
I think that you are correct that it is unrelated. In fact when I attempted to reproduce the errors that I previously encountered, they are no longer occurring.
Stacktrace: