sbt 1.x tool fails to install

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

sbt 1.x tool fails to install

Adam Shannon
Last week I updated the sbt crawler[0] to pull down 1.x releases. They're on a new download site. The archive format also changed (was zip, now runnable jar).

It seems the sbt plugin[1] is failing because it's trying to unpack the archive, when it should just attempt to run. (Only for 1.x)

I've tracked down the plugin source, but can't find where to add a branch for 0.13.x vs 1.x logic.

Here's a stack trace.
java.io.IOException: incorrect header check
	at com.jcraft.jzlib.InflaterInputStream.read(InflaterInputStream.java:112)
	at org.apache.commons.compress.utils.IOUtils.readFully(IOUtils.java:160)
	at org.apache.commons.compress.utils.IOUtils.readFully(IOUtils.java:134)
	at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.readRecord(TarArchiveInputStream.java:419)
	at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getRecord(TarArchiveInputStream.java:388)
	at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:269)
	at hudson.FilePath.readFromTar(FilePath.java:2295)
Also:   hudson.remoting.Channel$CallSiteStackTrace: Remote call to jenkins-agent (i-004e216e3ea36d6db)
		at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1693)
		at hudson.remoting.UserResponse.retrieve(UserRequest.java:310)
		at hudson.remoting.Channel.call(Channel.java:908)
		at hudson.FilePath.act(FilePath.java:986)
		at hudson.FilePath.act(FilePath.java:975)
		at hudson.FilePath.untarFrom(FilePath.java:723)
		at hudson.FilePath.installIfNecessaryFrom(FilePath.java:847)
		at hudson.FilePath.installIfNecessaryFrom(FilePath.java:763)
		at hudson.tools.DownloadFromUrlInstaller.performInstallation(DownloadFromUrlInstaller.java:77)
		at hudson.tools.InstallerTranslator.getToolHome(InstallerTranslator.java:72)
		at hudson.tools.ToolLocationNodeProperty.getToolHome(ToolLocationNodeProperty.java:109)
		at hudson.tools.ToolInstallation.translateFor(ToolInstallation.java:206)
		at org.jvnet.hudson.plugins.SbtPluginBuilder$SbtInstallation.forNode(SbtPluginBuilder.java:393)
		at org.jvnet.hudson.plugins.SbtPluginBuilder$SbtInstallation.forNode(SbtPluginBuilder.java:346)
		at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:152)
		at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:133)
		at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution$1$1.call(SynchronousNonBlockingStepExecution.java:49)
		at hudson.security.ACL.impersonate(ACL.java:260)
		at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution$1.run(SynchronousNonBlockingStepExecution.java:46)
		at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
Caused: java.io.IOException: Failed to extract input stream
	at hudson.FilePath.readFromTar(FilePath.java:2317)
	at hudson.FilePath.access$400(FilePath.java:196)
	at hudson.FilePath$10.invoke(FilePath.java:725)
	at hudson.FilePath$10.invoke(FilePath.java:723)
	at hudson.FilePath$FileCallableWrapper.call(FilePath.java:2760)
	at hudson.remoting.UserRequest.perform(UserRequest.java:207)
	at hudson.remoting.UserRequest.perform(UserRequest.java:53)
	at hudson.remoting.Request$2.run(Request.java:358)
	at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
Caused: java.io.IOException: remote file operation failed: /jenkins/tools/org.jvnet.hudson.plugins.SbtPluginBuilder_SbtInstallation/sbt at hudson.remoting.Channel@54c4e28d:jenkins-agent (i-004e216e3ea36d6db)
	at hudson.FilePath.act(FilePath.java:993)
	at hudson.FilePath.act(FilePath.java:975)
	at hudson.FilePath.untarFrom(FilePath.java:723)
	at hudson.FilePath.installIfNecessaryFrom(FilePath.java:847)
Caused: java.io.IOException: Failed to unpack https://repo1.maven.org/maven2/org/scala-sbt/sbt/1.1.0/sbt-1.1.0.jar (13170 bytes read of total 64341)
	at hudson.FilePath.installIfNecessaryFrom(FilePath.java:849)
Caused: java.io.IOException: Failed to install https://repo1.maven.org/maven2/org/scala-sbt/sbt/1.1.0/sbt-1.1.0.jar to /jenkins/tools/org.jvnet.hudson.plugins.SbtPluginBuilder_SbtInstallation/sbt
	at hudson.FilePath.installIfNecessaryFrom(FilePath.java:855)
	at hudson.FilePath.installIfNecessaryFrom(FilePath.java:763)
	at hudson.tools.DownloadFromUrlInstaller.performInstallation(DownloadFromUrlInstaller.java:77)
	at hudson.tools.InstallerTranslator.getToolHome(InstallerTranslator.java:72)
	at hudson.tools.ToolLocationNodeProperty.getToolHome(ToolLocationNodeProperty.java:109)
	at hudson.tools.ToolInstallation.translateFor(ToolInstallation.java:206)
	at org.jvnet.hudson.plugins.SbtPluginBuilder$SbtInstallation.forNode(SbtPluginBuilder.java:393)
	at org.jvnet.hudson.plugins.SbtPluginBuilder$SbtInstallation.forNode(SbtPluginBuilder.java:346)
	at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:152)
	at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:133)
	at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution$1$1.call(SynchronousNonBlockingStepExecution.java:49)
	at hudson.security.ACL.impersonate(ACL.java:260)
	at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution$1.run(SynchronousNonBlockingStepExecution.java:46)
	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)

I've also filed a PR for updating some of the docs with 1.0 links: https://github.com/jenkinsci/sbt-plugin/pull/19

[0]: https://github.com/jenkins-infra/crawler/pull/67#issuecomment-354823528
[1]: https://github.com/jenkinsci/sbt-plugin/blob/master/src/main/java/org/jvnet/hudson/plugins/SbtPluginBuilder.java

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/fcd77abb-bc20-4dc8-bc89-75bfb127c967%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: sbt 1.x tool fails to install

Adam Shannon
Actually, I found out that they offer .zip files for download. Let's try this fix first https://github.com/jenkins-infra/crawler/pull/68

On Monday, January 8, 2018 at 2:59:48 PM UTC-6, Adam Shannon wrote:
Last week I updated the sbt crawler[0] to pull down 1.x releases. They're on a new download site. The archive format also changed (was zip, now runnable jar).

It seems the sbt plugin[1] is failing because it's trying to unpack the archive, when it should just attempt to run. (Only for 1.x)

I've tracked down the plugin source, but can't find where to add a branch for 0.13.x vs 1.x logic.

Here's a stack trace.
java.io.IOException: incorrect header check
	at com.jcraft.jzlib.InflaterInputStream.read(InflaterInputStream.java:112)
	at org.apache.commons.compress.utils.IOUtils.readFully(IOUtils.java:160)
	at org.apache.commons.compress.utils.IOUtils.readFully(IOUtils.java:134)
	at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.readRecord(TarArchiveInputStream.java:419)
	at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getRecord(TarArchiveInputStream.java:388)
	at org.apache.commons.compress.archivers.tar.TarArchiveInputStream.getNextTarEntry(TarArchiveInputStream.java:269)
	at hudson.FilePath.readFromTar(FilePath.java:2295)
Also:   hudson.remoting.Channel$CallSiteStackTrace: Remote call to jenkins-agent (i-004e216e3ea36d6db)
		at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1693)
		at hudson.remoting.UserResponse.retrieve(UserRequest.java:310)
		at hudson.remoting.Channel.call(Channel.java:908)
		at hudson.FilePath.act(FilePath.java:986)
		at hudson.FilePath.act(FilePath.java:975)
		at hudson.FilePath.untarFrom(FilePath.java:723)
		at hudson.FilePath.installIfNecessaryFrom(FilePath.java:847)
		at hudson.FilePath.installIfNecessaryFrom(FilePath.java:763)
		at hudson.tools.DownloadFromUrlInstaller.performInstallation(DownloadFromUrlInstaller.java:77)
		at hudson.tools.InstallerTranslator.getToolHome(InstallerTranslator.java:72)
		at hudson.tools.ToolLocationNodeProperty.getToolHome(ToolLocationNodeProperty.java:109)
		at hudson.tools.ToolInstallation.translateFor(ToolInstallation.java:206)
		at org.jvnet.hudson.plugins.SbtPluginBuilder$SbtInstallation.forNode(SbtPluginBuilder.java:393)
		at org.jvnet.hudson.plugins.SbtPluginBuilder$SbtInstallation.forNode(SbtPluginBuilder.java:346)
		at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:152)
		at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:133)
		at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution$1$1.call(SynchronousNonBlockingStepExecution.java:49)
		at hudson.security.ACL.impersonate(ACL.java:260)
		at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution$1.run(SynchronousNonBlockingStepExecution.java:46)
		at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
Caused: java.io.IOException: Failed to extract input stream
	at hudson.FilePath.readFromTar(FilePath.java:2317)
	at hudson.FilePath.access$400(FilePath.java:196)
	at hudson.FilePath$10.invoke(FilePath.java:725)
	at hudson.FilePath$10.invoke(FilePath.java:723)
	at hudson.FilePath$FileCallableWrapper.call(FilePath.java:2760)
	at hudson.remoting.UserRequest.perform(UserRequest.java:207)
	at hudson.remoting.UserRequest.perform(UserRequest.java:53)
	at hudson.remoting.Request$2.run(Request.java:358)
	at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
Caused: java.io.IOException: remote file operation failed: /jenkins/tools/org.jvnet.hudson.plugins.SbtPluginBuilder_SbtInstallation/sbt at hudson.remoting.Channel@54c4e28d:jenkins-agent (i-004e216e3ea36d6db)
	at hudson.FilePath.act(FilePath.java:993)
	at hudson.FilePath.act(FilePath.java:975)
	at hudson.FilePath.untarFrom(FilePath.java:723)
	at hudson.FilePath.installIfNecessaryFrom(FilePath.java:847)
Caused: java.io.IOException: Failed to unpack <a href="https://repo1.maven.org/maven2/org/scala-sbt/sbt/1.1.0/sbt-1.1.0.jar" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Frepo1.maven.org%2Fmaven2%2Forg%2Fscala-sbt%2Fsbt%2F1.1.0%2Fsbt-1.1.0.jar\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGNWGdendP0YwVol-fG3NWTRZaG2A&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Frepo1.maven.org%2Fmaven2%2Forg%2Fscala-sbt%2Fsbt%2F1.1.0%2Fsbt-1.1.0.jar\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGNWGdendP0YwVol-fG3NWTRZaG2A&#39;;return true;">https://repo1.maven.org/maven2/org/scala-sbt/sbt/1.1.0/sbt-1.1.0.jar (13170 bytes read of total 64341)
	at hudson.FilePath.installIfNecessaryFrom(FilePath.java:849)
Caused: java.io.IOException: Failed to install <a href="https://repo1.maven.org/maven2/org/scala-sbt/sbt/1.1.0/sbt-1.1.0.jar" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Frepo1.maven.org%2Fmaven2%2Forg%2Fscala-sbt%2Fsbt%2F1.1.0%2Fsbt-1.1.0.jar\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGNWGdendP0YwVol-fG3NWTRZaG2A&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Frepo1.maven.org%2Fmaven2%2Forg%2Fscala-sbt%2Fsbt%2F1.1.0%2Fsbt-1.1.0.jar\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGNWGdendP0YwVol-fG3NWTRZaG2A&#39;;return true;">https://repo1.maven.org/maven2/org/scala-sbt/sbt/1.1.0/sbt-1.1.0.jar to /jenkins/tools/org.jvnet.hudson.plugins.SbtPluginBuilder_SbtInstallation/sbt
	at hudson.FilePath.installIfNecessaryFrom(FilePath.java:855)
	at hudson.FilePath.installIfNecessaryFrom(FilePath.java:763)
	at hudson.tools.DownloadFromUrlInstaller.performInstallation(DownloadFromUrlInstaller.java:77)
	at hudson.tools.InstallerTranslator.getToolHome(InstallerTranslator.java:72)
	at hudson.tools.ToolLocationNodeProperty.getToolHome(ToolLocationNodeProperty.java:109)
	at hudson.tools.ToolInstallation.translateFor(ToolInstallation.java:206)
	at org.jvnet.hudson.plugins.SbtPluginBuilder$SbtInstallation.forNode(SbtPluginBuilder.java:393)
	at org.jvnet.hudson.plugins.SbtPluginBuilder$SbtInstallation.forNode(SbtPluginBuilder.java:346)
	at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:152)
	at org.jenkinsci.plugins.workflow.steps.ToolStep$Execution.run(ToolStep.java:133)
	at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution$1$1.call(SynchronousNonBlockingStepExecution.java:49)
	at hudson.security.ACL.impersonate(ACL.java:260)
	at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution$1.run(SynchronousNonBlockingStepExecution.java:46)
	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)

I've also filed a PR for updating some of the docs with 1.0 links: <a href="https://github.com/jenkinsci/sbt-plugin/pull/19" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Fjenkinsci%2Fsbt-plugin%2Fpull%2F19\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNE1KGfoli87iXJXzOvvt_Ec4CSHyA&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Fjenkinsci%2Fsbt-plugin%2Fpull%2F19\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNE1KGfoli87iXJXzOvvt_Ec4CSHyA&#39;;return true;">https://github.com/jenkinsci/sbt-plugin/pull/19

[0]: <a href="https://github.com/jenkins-infra/crawler/pull/67#issuecomment-354823528" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Fjenkins-infra%2Fcrawler%2Fpull%2F67%23issuecomment-354823528\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGXR2E6w8Zyxrei-4Ier1yUQ6d4zw&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Fjenkins-infra%2Fcrawler%2Fpull%2F67%23issuecomment-354823528\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGXR2E6w8Zyxrei-4Ier1yUQ6d4zw&#39;;return true;">https://github.com/jenkins-infra/crawler/pull/67#issuecomment-354823528
[1]: <a href="https://github.com/jenkinsci/sbt-plugin/blob/master/src/main/java/org/jvnet/hudson/plugins/SbtPluginBuilder.java" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Fjenkinsci%2Fsbt-plugin%2Fblob%2Fmaster%2Fsrc%2Fmain%2Fjava%2Forg%2Fjvnet%2Fhudson%2Fplugins%2FSbtPluginBuilder.java\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHud6w8HP0iHik4ioZwAcQOuidfcA&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Fjenkinsci%2Fsbt-plugin%2Fblob%2Fmaster%2Fsrc%2Fmain%2Fjava%2Forg%2Fjvnet%2Fhudson%2Fplugins%2FSbtPluginBuilder.java\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHud6w8HP0iHik4ioZwAcQOuidfcA&#39;;return true;">https://github.com/jenkinsci/sbt-plugin/blob/master/src/main/java/org/jvnet/hudson/plugins/SbtPluginBuilder.java

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/a1c8c7e1-a27c-4782-9cab-457b82f4ae08%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.