Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build: Bump junit to 5.12.1, nessie to 0.103.2 #12391

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

iProdigy
Copy link

@iProdigy iProdigy commented Feb 23, 2025

Closes #12378
Closes #12381
Closes #12537
Closes #12538

As of Gradle 8, not explicitly depending upon junit-platform-launcher is deprecated (and will be required in Gradle 9)

Also adds junit-bom as per their recommendation

@github-actions github-actions bot added the build label Feb 23, 2025
build.gradle Outdated
@@ -198,8 +198,10 @@ subprojects {
dependencies {
implementation libs.slf4j.api

testImplementation platform(libs.junit.bom)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's leave introducing the BOM out for now. We can do that in a separate PR, where we'd also clean up how dependencies are defined for JUnit (e.g. similar to

iceberg/build.gradle

Lines 460 to 471 in d6d97d1

compileOnly(platform(libs.awssdk.bom))
compileOnly(libs.awssdk.s3accessgrants)
compileOnly("software.amazon.awssdk:url-connection-client")
compileOnly("software.amazon.awssdk:apache-client")
compileOnly("software.amazon.awssdk:auth")
compileOnly("software.amazon.awssdk:http-auth-aws-crt")
compileOnly("software.amazon.awssdk:s3")
compileOnly("software.amazon.awssdk:kms")
compileOnly("software.amazon.awssdk:glue")
compileOnly("software.amazon.awssdk:sts")
compileOnly("software.amazon.awssdk:dynamodb")
compileOnly("software.amazon.awssdk:lakeformation")
). Are you interested in introducing the BOM in a separate PR?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I'd be happy to do the bom PR too (given this one still passes CI)

@nastra
Copy link
Contributor

nastra commented Feb 24, 2025

Looks like tests in the iceberg-nessie module fail due to

org.gradle.api.internal.tasks.testing.TestSuiteExecutionException: Could not start Gradle Test Executor 3.
	at org.gradle.api.internal.tasks.testing.SuiteTestClassProcessor.startProcessing(SuiteTestClassProcessor.java:45)
	at java.base@11.0.23/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base@11.0.23/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base@11.0.23/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base@11.0.23/java.lang.reflect.Method.invoke(Method.java:566)
	at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:36)
	at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24)
	at org.gradle.internal.dispatch.ContextClassLoaderDispatch.dispatch(ContextClassLoaderDispatch.java:33)
	at org.gradle.internal.dispatch.ProxyDispatchAdapter$DispatchingInvocationHandler.invoke(ProxyDispatchAdapter.java:92)
	at com.sun.proxy.$Proxy4.startProcessing(Unknown Source)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker$1.run(TestWorker.java:168)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker.executeAndMaintainThreadName(TestWorker.java:132)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:103)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:63)
	at org.gradle.process.internal.worker.child.ActionExecutionWorker.execute(ActionExecutionWorker.java:56)
	at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:121)
	at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:71)
	at app//worker.org.gradle.process.internal.worker.GradleWorkerMain.run(GradleWorkerMain.java:69)
	at app//worker.org.gradle.process.internal.worker.GradleWorkerMain.main(GradleWorkerMain.java:74)
Caused by: java.util.ServiceConfigurationError: org.junit.platform.engine.TestEngine: Provider org.projectnessie.junit.engine.MultiEnvTestEngine could not be instantiated
	at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:582)
	at java.base/java.util.ServiceLoader$ProviderImpl.newInstance(ServiceLoader.java:804)
	at java.base/java.util.ServiceLoader$ProviderImpl.get(ServiceLoader.java:722)
	at java.base/java.util.ServiceLoader$3.next(ServiceLoader.java:1395)
	at java.base/java.lang.Iterable.forEach(Iterable.java:74)
	at org.junit.platform.launcher.core.LauncherFactory.collectTestEngines(LauncherFactory.java:158)
	at org.junit.platform.launcher.core.LauncherFactory.createDefaultLauncher(LauncherFactory.java:134)
	at org.junit.platform.launcher.core.LauncherFactory.lambda$openSession$1(LauncherFactory.java:99)
	at org.junit.platform.launcher.core.ClasspathAlignmentCheckingLauncherInterceptor.intercept(ClasspathAlignmentCheckingLauncherInterceptor.java:25)
	at org.junit.platform.launcher.core.DefaultLauncherSession.<init>(DefaultLauncherSession.java:57)
	at org.junit.platform.launcher.core.LauncherFactory.openSession(LauncherFactory.java:98)
	at org.junit.platform.launcher.core.LauncherFactory.openSession(LauncherFactory.java:80)
	at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor$BackwardsCompatibleLauncherSession.open(JUnitPlatformTestClassProcessor.java:323)
	at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor.createTestExecutor(JUnitPlatformTestClassProcessor.java:86)
	at org.gradle.api.internal.tasks.testing.junit.AbstractJUnitTestClassProcessor.startProcessing(AbstractJUnitTestClassProcessor.java:44)
	at org.gradle.api.internal.tasks.testing.SuiteTestClassProcessor.startProcessing(SuiteTestClassProcessor.java:43)
	... 18 more
Caused by: java.lang.NoSuchMethodError: 'void org.junit.jupiter.engine.config.DefaultJupiterConfiguration.<init>(org.junit.platform.engine.ConfigurationParameters)'
	at org.projectnessie.junit.engine.MultiEnvExtensionRegistry.<init>(MultiEnvExtensionRegistry.java:43)
	at org.projectnessie.junit.engine.MultiEnvTestEngine.<clinit>(MultiEnvTestEngine.java:53)
	at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
	at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
	at java.base/java.util.ServiceLoader$ProviderImpl.newInstance(ServiceLoader.java:780)
	... 32 more

@ajantha-bhat could you take a look please?

@ajantha-bhat
Copy link
Member

@nastra: We probably need this PR to get merged first at Nessie side.
projectnessie/nessie#10442

Looks like Junit 5.12.0 has some breaking changes that need a new Nessie release so that we can fix "org.projectnessie.junit.engine.MultiEnvTestEngine could not be instantiated" error.

cc: @snazy, @dimas-b

@iProdigy iProdigy changed the title Build: Bump junit to v5.12.0 Build: Bump junit to v5.12.1 Mar 14, 2025
@iProdigy iProdigy marked this pull request as draft March 14, 2025 14:21
@iProdigy iProdigy changed the title Build: Bump junit to v5.12.1 Build: Bump junit to 5.12.1, nessie to 0.103.2 Mar 21, 2025
@iProdigy iProdigy marked this pull request as ready for review March 21, 2025 23:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants