英文:
gradle build broken after dependency update
问题
I use gradle to build a java project (ASCIIGenome).
One of the dependencies of ASCIIGenome is a repository on GitHub (htsjdk, as you can see, it's a fork with some of my changes). The ASCIIGenome project builds successfully if I use this commit of htsjdk
in build.gradle
:
dependencies {
...
compile 'com.github.dariober:htsjdk:80e355c'
...
}
I made edits to htsjdk, so now the dependency is:
compile 'com.github.dariober:htsjdk:609ca91'
However, after making this change, the build fails with the following error:
./gradlew build
FAILURE: Build failed with an exception.
* Where:
Build file '/home/dario/git_repos/ASCIIGenome/build.gradle' line: 77
* What went wrong:
Could not determine the dependencies of task ':jar'.
> Could not resolve all files for configuration ':compile'.
> Could not find com.github.dariober:htsjdk:609ca91.
Searched in the following locations:
- https://jcenter.bintray.com/com/github/dariober/htsjdk/609ca91/htsjdk-609ca91.pom
- https://jcenter.bintray.com/com/github/dariober/htsjdk/609ca91/htsjdk-609ca91.jar
- https://jitpack.io/com/github/dariober/htsjdk/609ca91/htsjdk-609ca91.pom
- https://jitpack.io/com/github/dariober/htsjdk/609ca91/htsjdk-609ca91.jar
Required by:
project :
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 3s
I can't understand why htsjdk:80e355c is working fine, while htsjdk:609ca91 is causing the build to fail. Do you have any idea which changes might be breaking the build? Please let me know if more information is needed.
英文:
I use gradle to build a java project (ASCIIGenome).
One of the dependencies of ASCIIGenome is a repository on github (htsjdk, as you can see is a fork with some changes of mine). The ASCIIGenome project builds fine if I use this commit of htsjdk
in build.gradle
:
dependencies {
...
compile 'com.github.dariober:htsjdk:80e355c'
...
}
I made edits to htsjdk so now the dependency is
compile 'com.github.dariober:htsjdk:609ca91'
and now the build fails with the following:
./gradlew build
FAILURE: Build failed with an exception.
* Where:
Build file '/home/dario/git_repos/ASCIIGenome/build.gradle' line: 77
* What went wrong:
Could not determine the dependencies of task ':jar'.
> Could not resolve all files for configuration ':compile'.
> Could not find com.github.dariober:htsjdk:609ca91.
Searched in the following locations:
- https://jcenter.bintray.com/com/github/dariober/htsjdk/609ca91/htsjdk-609ca91.pom
- https://jcenter.bintray.com/com/github/dariober/htsjdk/609ca91/htsjdk-609ca91.jar
- https://jitpack.io/com/github/dariober/htsjdk/609ca91/htsjdk-609ca91.pom
- https://jitpack.io/com/github/dariober/htsjdk/609ca91/htsjdk-609ca91.jar
Required by:
project :
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 3s
I can't understand why htsjdk:80e355c is ok while htsjdk:609ca91 fails. Any idea what changes break the build? Please let me know if more information is necessary
答案1
得分: 1
这原来是 htsjdk 的 .gitignore 仓库中有一个错误,导致某些文件被忽略,因此 htsjdk 依赖关系出现问题。修复 .gitignore 后,问题得以解决。
英文:
It turns out there is a bug in the .gitignore repository of htsjdk that caused some files to be ignored so the htsjdk dependency was broken. Fixing .gitignore fixed my problem.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论