Gradle: Could not HEAD 'http://repo1.maven.org/maven2/commons-cli/commons-cli/1.1/c ommons-cli-1.1.jar'.

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Gradle: Could not HEAD 'http://repo1.maven.org/maven2/commons-cli/commons-cli/1.1/c ommons-cli-1.1.jar'.

saketk
This post has NOT been accepted by the mailing list yet.
I am using gradle 1.2. Getting the below error with stacktrace while it loads dependencies. Please help with the stacktrace as I am not able to resolve it for quite sometime. Thanks


* What went wrong:
Could not resolve all dependencies for configuration ':pid-portlet:compile'.
> Could not download artifact 'commons-cli:commons-cli:1.1@jar'
   > Could not HEAD 'http://repo1.maven.org/maven2/commons-cli/commons-cli/1.1/c
ommons-cli-1.1.jar'.

* Try:
Run with --info or --debug option to get more log output.

* Exception is:
org.gradle.api.artifacts.ResolveException: Could not resolve all dependencies fo
r configuration ':pid-portlet:compile'.
        at org.gradle.api.internal.artifacts.ivyservice.ErrorHandlingArtifactDep
endencyResolver.wrapException(ErrorHandlingArtifactDependencyResolver.java:48)
        at org.gradle.api.internal.artifacts.ivyservice.ErrorHandlingArtifactDep
endencyResolver.access$000(ErrorHandlingArtifactDependencyResolver.java:27)
        at org.gradle.api.internal.artifacts.ivyservice.ErrorHandlingArtifactDep
endencyResolver$ErrorHandlingResolvedConfiguration.getFiles(ErrorHandlingArtifac
tDependencyResolver.java:81)
        at org.gradle.api.internal.artifacts.configurations.DefaultConfiguration
$ConfigurationFileCollection.getFiles(DefaultConfiguration.java:460)
        at org.gradle.api.internal.artifacts.configurations.DefaultConfiguration
.getFiles(DefaultConfiguration.java:203)
        at org.gradle.api.internal.artifacts.configurations.DefaultConfiguration
_Decorated.getFiles(Unknown Source)
        at org.gradle.api.internal.file.collections.DefaultFileCollectionResolve
Context$FileTreeConverter.convertInto(DefaultFileCollectionResolveContext.java:1
91)
        at org.gradle.api.internal.file.collections.DefaultFileCollectionResolve
Context.doResolve(DefaultFileCollectionResolveContext.java:103)
        at org.gradle.api.internal.file.collections.DefaultFileCollectionResolve
Context.resolveAsFileTrees(DefaultFileCollectionResolveContext.java:75)
        at org.gradle.api.internal.file.collections.DefaultFileCollectionResolve
Context$FileTreeConverter.convertInto(DefaultFileCollectionResolveContext.java:1
82)
        at org.gradle.api.internal.file.collections.DefaultFileCollectionResolve
Context.doResolve(DefaultFileCollectionResolveContext.java:98)
        at org.gradle.api.internal.file.collections.DefaultFileCollectionResolve
Context.resolveAsFileTrees(DefaultFileCollectionResolveContext.java:75)
        at org.gradle.api.internal.file.CompositeFileCollection$1.resolve(Compos
iteFileCollection.java:88)
        at org.gradle.api.internal.file.CompositeFileCollection.getSourceCollect
ions(CompositeFileCollection.java:143)
        at org.gradle.api.internal.file.CompositeFileTree.getSourceCollections(C
ompositeFileTree.java:30)
        at org.gradle.api.internal.file.CompositeFileCollection.getFiles(Composi
teFileCollection.java:38)
        at org.gradle.api.internal.file.AbstractFileCollection.iterator(Abstract
FileCollection.java:60)
        at org.gradle.api.internal.changedetection.DefaultFileSnapshotter.snapsh
ot(DefaultFileSnapshotter.java:42)
        at org.gradle.api.internal.changedetection.InputFilesChangedUpToDateRule
.create(InputFilesChangedUpToDateRule.java:35)
        at org.gradle.api.internal.changedetection.CompositeUpToDateRule.create(
CompositeUpToDateRule.java:35)
        at org.gradle.api.internal.changedetection.DefaultTaskArtifactStateRepos
itory$HistoricExecution.calcCurrentState(DefaultTaskArtifactStateRepository.java
:80)
        at org.gradle.api.internal.changedetection.DefaultTaskArtifactStateRepos
itory$HistoricExecution.isUpToDate(DefaultTaskArtifactStateRepository.java:88)
        at org.gradle.api.internal.changedetection.DefaultTaskArtifactStateRepos
itory$TaskArtifactStateImpl.isUpToDate(DefaultTaskArtifactStateRepository.java:1
28)
        at org.gradle.api.internal.changedetection.ShortCircuitTaskArtifactState
Repository$ShortCircuitArtifactState.isUpToDate(ShortCircuitTaskArtifactStateRep
ository.java:77)
        at org.gradle.api.internal.changedetection.FileCacheBroadcastTaskArtifac
tStateRepository$1.isUpToDate(FileCacheBroadcastTaskArtifactStateRepository.java
:37)
        at org.gradle.api.internal.tasks.execution.SkipUpToDateTaskExecuter.exec
ute(SkipUpToDateTaskExecuter.java:44)
        at org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execut
e(ValidatingTaskExecuter.java:57)
        at org.gradle.api.internal.tasks.execution.SkipEmptySourceFilesTaskExecu
ter.execute(SkipEmptySourceFilesTaskExecuter.java:41)
        at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter
.execute(SkipTaskWithNoActionsExecuter.java:51)
        at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execut
e(SkipOnlyIfTaskExecuter.java:52)
        at org.gradle.api.internal.tasks.execution.ExecuteAtMostOnceTaskExecuter
.execute(ExecuteAtMostOnceTaskExecuter.java:42)
        at org.gradle.api.internal.AbstractTask.executeWithoutThrowingTaskFailur
e(AbstractTask.java:247)
        at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor.executeTask(De
faultTaskPlanExecutor.java:52)
        at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor.processTask(De
faultTaskPlanExecutor.java:38)
        at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor.process(Defaul
tTaskPlanExecutor.java:30)
        at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter.execute(Defau
ltTaskGraphExecuter.java:83)
        at org.gradle.execution.SelectedTaskExecutionAction.execute(SelectedTask
ExecutionAction.java:29)
        at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecute
r.java:61)
        at org.gradle.execution.DefaultBuildExecuter.access$200(DefaultBuildExec
uter.java:23)
        at org.gradle.execution.DefaultBuildExecuter$2.proceed(DefaultBuildExecu
ter.java:67)
        at org.gradle.api.internal.changedetection.TaskCacheLockHandlingBuildExe
cuter$1.run(TaskCacheLockHandlingBuildExecuter.java:31)
        at org.gradle.cache.internal.DefaultCacheAccess$2.create(DefaultCacheAcc
ess.java:118)
        at org.gradle.cache.internal.DefaultCacheAccess.useCache(DefaultCacheAcc
ess.java:133)
        at org.gradle.cache.internal.DefaultCacheAccess.useCache(DefaultCacheAcc
ess.java:116)
        at org.gradle.cache.internal.DefaultPersistentDirectoryStore.useCache(De
faultPersistentDirectoryStore.java:129)
        at org.gradle.api.internal.changedetection.DefaultTaskArtifactStateCache
Access.useCache(DefaultTaskArtifactStateCacheAccess.java:79)
        at org.gradle.api.internal.changedetection.TaskCacheLockHandlingBuildExe
cuter.execute(TaskCacheLockHandlingBuildExecuter.java:29)
        at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecute
r.java:61)
        at org.gradle.execution.DefaultBuildExecuter.access$200(DefaultBuildExec
uter.java:23)
        at org.gradle.execution.DefaultBuildExecuter$2.proceed(DefaultBuildExecu
ter.java:67)
        at org.gradle.execution.DryRunBuildExecutionAction.execute(DryRunBuildEx
ecutionAction.java:32)
        at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecute
r.java:61)
        at org.gradle.execution.DefaultBuildExecuter.execute(DefaultBuildExecute
r.java:54)
        at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(Default
GradleLauncher.java:158)
        at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradle
Launcher.java:113)
        at org.gradle.initialization.DefaultGradleLauncher.run(DefaultGradleLaun
cher.java:81)
        at org.gradle.launcher.cli.ExecuteBuildAction.run(ExecuteBuildAction.jav
a:38)
        at org.gradle.launcher.exec.InProcessGradleLauncherActionExecuter.execut
e(InProcessGradleLauncherActionExecuter.java:39)
        at org.gradle.launcher.exec.InProcessGradleLauncherActionExecuter.execut
e(InProcessGradleLauncherActionExecuter.java:25)
        at org.gradle.launcher.cli.RunBuildAction.run(RunBuildAction.java:50)
        at org.gradle.launcher.cli.ActionAdapter.execute(ActionAdapter.java:30)
        at org.gradle.launcher.cli.ActionAdapter.execute(ActionAdapter.java:22)
        at org.gradle.launcher.cli.CommandLineActionFactory$ParseAndBuildAction.
execute(CommandLineActionFactory.java:200)
        at org.gradle.launcher.cli.CommandLineActionFactory$ParseAndBuildAction.
execute(CommandLineActionFactory.java:173)
        at org.gradle.launcher.cli.CommandLineActionFactory$WithLogging.execute(
CommandLineActionFactory.java:169)
        at org.gradle.launcher.cli.CommandLineActionFactory$WithLogging.execute(
CommandLineActionFactory.java:138)
        at org.gradle.launcher.cli.ExceptionReportingAction.execute(ExceptionRep
ortingAction.java:33)
        at org.gradle.launcher.cli.ExceptionReportingAction.execute(ExceptionRep
ortingAction.java:22)
        at org.gradle.launcher.Main.doAction(Main.java:48)
        at org.gradle.launcher.bootstrap.EntryPoint.run(EntryPoint.java:45)
        at org.gradle.launcher.Main.main(Main.java:39)
        at org.gradle.launcher.bootstrap.ProcessBootstrap.runNoExit(ProcessBoots
trap.java:50)
        at org.gradle.launcher.bootstrap.ProcessBootstrap.run(ProcessBootstrap.j
ava:32)
        at org.gradle.launcher.GradleMain.main(GradleMain.java:26)
Caused by: org.gradle.api.internal.artifacts.ivyservice.ivyresolve.ArtifactResol
veException: Could not download artifact 'commons-cli:commons-cli:1.1@jar'
        at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.DependencyRes
olverAdapter.download(DependencyResolverAdapter.java:74)
        at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.CacheLockingM
oduleVersionRepository$2.create(CacheLockingModuleVersionRepository.java:59)
        at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.CacheLockingM
oduleVersionRepository$2.create(CacheLockingModuleVersionRepository.java:57)
        at org.gradle.cache.internal.DefaultCacheAccess.longRunningOperation(Def
aultCacheAccess.java:188)
        at org.gradle.cache.internal.DefaultPersistentDirectoryStore.longRunning
Operation(DefaultPersistentDirectoryStore.java:133)
        at org.gradle.api.internal.artifacts.ivyservice.DefaultCacheLockingManag
er.longRunningOperation(DefaultCacheLockingManager.java:57)
        at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.CacheLockingM
oduleVersionRepository.download(CacheLockingModuleVersionRepository.java:57)
        at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.CachingModule
VersionRepository.download(CachingModuleVersionRepository.java:221)
        at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.IvyContextual
iser$1.invoke(IvyContextualiser.java:44)
        at com.sun.proxy.$Proxy37.download(Unknown Source)
        at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.UserResolverC
hain$ModuleVersionRepositoryBackedArtifactResolver.resolve(UserResolverChain.jav
a:163)
        at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.LazyDependenc
yToModuleResolver$ErrorHandlingArtifactResolver.resolve(LazyDependencyToModuleRe
solver.java:59)
        at org.gradle.api.internal.artifacts.ivyservice.ResolvedArtifactFactory$
1$1.create(ResolvedArtifactFactory.java:38)
        at org.gradle.api.internal.artifacts.ivyservice.ResolvedArtifactFactory$
1$1.create(ResolvedArtifactFactory.java:36)
        at org.gradle.cache.internal.DefaultCacheAccess.useCache(DefaultCacheAcc
ess.java:133)
        at org.gradle.cache.internal.DefaultPersistentDirectoryStore.useCache(De
faultPersistentDirectoryStore.java:125)
        at org.gradle.api.internal.artifacts.ivyservice.DefaultCacheLockingManag
er.useCache(DefaultCacheLockingManager.java:49)
        at org.gradle.api.internal.artifacts.ivyservice.ResolvedArtifactFactory$
1.create(ResolvedArtifactFactory.java:36)
        at org.gradle.api.internal.artifacts.ivyservice.ResolvedArtifactFactory$
1.create(ResolvedArtifactFactory.java:34)
        at org.gradle.api.internal.artifacts.DefaultResolvedArtifact.getFile(Def
aultResolvedArtifact.java:117)
        at org.gradle.api.internal.artifacts.ivyservice.DefaultLenientConfigurat
ion.getFiles(DefaultLenientConfiguration.java:126)
        at org.gradle.api.internal.artifacts.ivyservice.DefaultLenientConfigurat
ion.getFilesStrict(DefaultLenientConfiguration.java:101)
        at org.gradle.api.internal.artifacts.ivyservice.DefaultResolvedConfigura
tion.getFiles(DefaultResolvedConfiguration.java:48)
        at org.gradle.api.internal.artifacts.ivyservice.SelfResolvingDependencyR
esolver$1.getFiles(SelfResolvingDependencyResolver.java:57)
        at org.gradle.api.internal.artifacts.ivyservice.ErrorHandlingArtifactDep
endencyResolver$ErrorHandlingResolvedConfiguration.getFiles(ErrorHandlingArtifac
tDependencyResolver.java:79)
        ... 71 more
Caused by: org.gradle.api.UncheckedIOException: Could not HEAD 'http://repo1.mav
en.org/maven2/commons-cli/commons-cli/1.1/commons-cli-1.1.jar'.
        at org.gradle.api.internal.externalresource.transport.http.HttpClientHel
per.performRequest(HttpClientHelper.java:71)
        at org.gradle.api.internal.externalresource.transport.http.HttpClientHel
per.performRawHead(HttpClientHelper.java:49)
        at org.gradle.api.internal.externalresource.transport.http.HttpClientHel
per.performHead(HttpClientHelper.java:53)
        at org.gradle.api.internal.externalresource.transport.http.HttpResourceA
ccessor.getMetaData(HttpResourceAccessor.java:65)
        at org.gradle.api.internal.externalresource.transfer.ProgressLoggingExte
rnalResourceAccessor.getMetaData(ProgressLoggingExternalResourceAccessor.java:53
)
        at org.gradle.api.internal.externalresource.transfer.DefaultCacheAwareEx
ternalResourceAccessor.getResource(DefaultCacheAwareExternalResourceAccessor.jav
a:56)
        at org.gradle.api.internal.artifacts.repositories.DefaultExternalResourc
eRepository.getResource(DefaultExternalResourceRepository.java:63)
        at org.gradle.api.internal.artifacts.repositories.ExternalResourceResolv
er.getResource(ExternalResourceResolver.java:338)
        at org.gradle.api.internal.artifacts.repositories.ExternalResourceResolv
er.findStaticResourceUsingPattern(ExternalResourceResolver.java:240)
        at org.gradle.api.internal.artifacts.repositories.ExternalResourceResolv
er.findResourceUsingPattern(ExternalResourceResolver.java:226)
        at org.gradle.api.internal.artifacts.repositories.ExternalResourceResolv
er.findResourceUsingPatterns(ExternalResourceResolver.java:147)
        at org.gradle.api.internal.artifacts.repositories.MavenResolver.getArtif
actRef(MavenResolver.java:157)
        at org.gradle.api.internal.artifacts.repositories.ExternalResourceResolv
er.getArtifactRef(ExternalResourceResolver.java:130)
        at org.apache.ivy.plugins.resolver.BasicResolver$5.resolve(BasicResolver
.java:1024)
        at org.gradle.api.internal.artifacts.repositories.cachemanager.Downloadi
ngRepositoryCacheManager.download(DownloadingRepositoryCacheManager.java:70)
        at org.apache.ivy.plugins.resolver.BasicResolver.download(BasicResolver.
java:726)
        at org.gradle.api.internal.artifacts.ivyservice.ivyresolve.DependencyRes
olverAdapter.download(DependencyResolverAdapter.java:70)
        ... 95 more
Caused by: java.net.UnknownHostException: repo1.maven.org
        at org.apache.http.impl.conn.SystemDefaultDnsResolver.resolve(SystemDefa
ultDnsResolver.java:45)
        at org.apache.http.impl.conn.DefaultClientConnectionOperator.resolveHost
name(DefaultClientConnectionOperator.java:278)
        at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnect
ion(DefaultClientConnectionOperator.java:162)
        at org.apache.http.impl.conn.ManagedClientConnectionImpl.open(ManagedCli
entConnectionImpl.java:294)
        at org.apache.http.impl.client.DefaultRequestDirector.tryConnect(Default
RequestDirector.java:640)
        at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultReq
uestDirector.java:479)
        at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpCl
ient.java:906)
        at org.apache.http.impl.client.DecompressingHttpClient.execute(Decompres
singHttpClient.java:137)
        at org.apache.http.impl.client.DecompressingHttpClient.execute(Decompres
singHttpClient.java:118)
        at org.gradle.api.internal.externalresource.transport.http.HttpClientHel
per.performHttpRequest(HttpClientHelper.java:102)
        at org.gradle.api.internal.externalresource.transport.http.HttpClientHel
per.executeGetOrHead(HttpClientHelper.java:78)
        at org.gradle.api.internal.externalresource.transport.http.HttpClientHel
per.performRequest(HttpClientHelper.java:69)
        ... 111 more
Reply | Threaded
Open this post in threaded view
|

Re: Gradle: Could not HEAD 'http://repo1.maven.org/maven2/commons-cli/commons-cli/1.1/c ommons-cli-1.1.jar'.

saketk
replying as not accepted
Reply | Threaded
Open this post in threaded view
|

Re: Gradle: Could not HEAD 'http://repo1.maven.org/maven2/commons-cli/commons-cli/1.1/c ommons-cli-1.1.jar'.

Peter Niederwieser
In reply to this post by saketk
The user mailing list is no longer monitored actively. Please use http://forums.gradle.org.