From 751ab29c36222ccf7237dfb1ad1deb6d62f9a511 Mon Sep 17 00:00:00 2001 From: Vankka Date: Sun, 17 Nov 2024 00:30:09 +0200 Subject: [PATCH] Rollback to slf4j-api v1 --- api/build.gradle | 3 +++ bukkit/paper/build.gradle | 5 ++++- settings.gradle | 5 ++++- velocity/build.gradle | 9 +++++++-- 4 files changed, 18 insertions(+), 4 deletions(-) diff --git a/api/build.gradle b/api/build.gradle index b9e04f2f..3f7df44e 100644 --- a/api/build.gradle +++ b/api/build.gradle @@ -12,8 +12,11 @@ dependencies { api(libs.jda) { // We don't use audio exclude module: 'opus-java' + // v2 + exclude module: 'slf4j-api' } api(libs.okhttp) + api(libs.slf4j.api) } // Relocations are in buildscript/api.gradle diff --git a/bukkit/paper/build.gradle b/bukkit/paper/build.gradle index e67adf24..0b7597e0 100644 --- a/bukkit/paper/build.gradle +++ b/bukkit/paper/build.gradle @@ -4,7 +4,10 @@ java { dependencies { // Platform - compileOnly(libs.paperapi) + compileOnly(libs.paperapi) { + // v2 + exclude module: 'slf4j-api' + } // Adventure (runtime downloaded by :bukkit) compileOnly(libs.adventure.platform.bukkit) diff --git a/settings.gradle b/settings.gradle index 7400618e..41afd9a5 100644 --- a/settings.gradle +++ b/settings.gradle @@ -116,7 +116,10 @@ dependencyResolutionManagement { library('essentialsx', 'net.essentialsx', 'EssentialsX').version('2.20.1') // Logging - library('slf4j-api', 'org.slf4j', 'slf4j-api').version('1.7.36') + library('slf4j-api', 'org.slf4j', 'slf4j-api').version { + prefer '1.7.36' + reject '[2,)' // Uses ServiceLoader + } library('log4j-core', 'org.apache.logging.log4j', 'log4j-core').version('2.0-beta9') // Adventure diff --git a/velocity/build.gradle b/velocity/build.gradle index 28708941..18d85c8e 100644 --- a/velocity/build.gradle +++ b/velocity/build.gradle @@ -43,9 +43,14 @@ dependencies { implementation project(':common') // Platform - annotationProcessor(libs.velocity) + annotationProcessor(libs.velocity) { + // v2 + exclude module: 'slf4j-api' + } compileOnly(libs.velocity) { exclude module: 'caffeine' + // v2 + exclude module: 'slf4j-api' } // DependencyDownload @@ -54,6 +59,6 @@ dependencies { tasks { runVelocity { - velocityVersion("3.1.2-SNAPSHOT") + velocityVersion(libs.velocity.get().version) } } \ No newline at end of file