Anyone else having issues running kt lint? Have been seeing this occur for about a day now
Copy code
> Could not resolve all files for configuration ':udisc:ktlint'.
> Could not resolve org.ec4j.core:ec4j-core:0.3.0.
Required by:
project :udisc > com.pinterest:ktlint:0.42.1 > com.pinterest.ktlint:ktlint-core:0.42.1
> Could not resolve org.ec4j.core:ec4j-core:0.3.0.
> Could not get resource '<https://www.jitpack.io/org/ec4j/core/ec4j-core/0.3.0/ec4j-core-0.3.0.pom>'.
> Could not GET '<https://www.jitpack.io/org/ec4j/core/ec4j-core/0.3.0/ec4j-core-0.3.0.pom>'.
> Read timed out
yeah i saw that as well. Im consuming it through https://github.com/JLLeitschuh/ktlint-gradle if that means anything. Maybe its just an issue with Github Actions or something 🤷♂️
t
tapchicoma
03/31/2022, 12:30 PM
ktlint-gradle does not define repositories where to get dependencies. Check your build script for repositories definition - probably jitpack.io should be moved below
mavenCentral()
t
Tyler Turnbull
03/31/2022, 12:44 PM
awesome, that worked. Thanks so much @tapchicoma. I never realized that order of repositories is important but that makes sense.
👍 2
e
ephemient
03/31/2022, 7:11 PM
you would also have avoided this by restricting what content is retrieved from the jitpack repo, e.g.
Copy code
repositories {
maven("<https://jitpack.io>") {
// don't use jitpack for anything else
content {
includeModule("com.github.user", "repo")
}
}
}