From 28c41a9e36be3821569c7fc7f9cefd96a40f5ce8 Mon Sep 17 00:00:00 2001 From: Ruslan Dautkhanov Date: Thu, 21 May 2026 11:09:18 -0600 Subject: [PATCH] build: drop jcenter() in favor of mavenCentral + gradlePluginPortal MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The Gradle buildscript declared `jcenter()` as the sole repository for buildscript classpath resolution (spotless 1.3.2 + bnd-platform 1.3.0). JFrog sunset JCenter / Bintray in May 2021; the endpoint is now flaky — CI runners whose gradle cache happens to have the artifacts cached pass; fresh runners (notably windows-latest) intermittently fail dependency resolution: Could not resolve com.diffplug.gradle.spotless:spotless:1.3.2. > Could not get resource 'https://jcenter.bintray.com/com/diffplug/gradle/spotless/spotless/1.3.2/spotless-1.3.2.pom'. Observed on the master push CI for #7 (1 of 56 cells failed: Python 3.9 / Java 17 / windows-latest), and intermittently on prior runs. Replace with mavenCentral() + gradlePluginPortal(). Both classpath artifacts are mirrored on Maven Central; gradlePluginPortal() is added as a defensive fallback for any future plugin lookups. Verified locally: clean gradle cache (`rm -rf ~/.gradle/caches/modules-2/files-2.1/com.diffplug.gradle.spotless` and bnd-platform) + `./gradlew --refresh-dependencies classes testClasses` → BUILD SUCCESSFUL with the new repositories. Co-authored-by: Isaac --- py4j-java/build.gradle | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/py4j-java/build.gradle b/py4j-java/build.gradle index f9821ded..1a2bff91 100644 --- a/py4j-java/build.gradle +++ b/py4j-java/build.gradle @@ -80,7 +80,14 @@ if (JavaVersion.current().isJava8Compatible()) { buildscript { repositories { - jcenter() + // jcenter() (JFrog Bintray) was sunset in May 2021 and is + // increasingly unreliable — fresh CI runners (e.g. windows- + // latest with an empty gradle cache) fail dependency + // resolution intermittently. Both classpath artifacts below + // are mirrored on Maven Central; the gradle plugin portal + // is added as a defensive fallback for plugin resolution. + mavenCentral() + gradlePluginPortal() } dependencies { // Only add spotless for JDK >= 1.8