我在项目中使用logback
作为依赖项,并获得以下输出:
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:~/.gradle/caches/4.10/generated-gradle-jars/gradle-api-4.10.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:~/.gradle/caches/modules-2/files-2.1/ch.qos.logback/logback-classic/1.2.3/7c4f3c474fb2c041d8028740440937705ebb473a/logback-classic-1.2.3.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.gradle.internal.logging.slf4j.OutputEventListenerBackedLoggerContext]
我阅读了很多类似的问题和答案。他们中的大多数建议将相应的exclude
添加到额外的依赖项中。但是我无法想象其中哪些与gradle-api-4.10.jar
相关。浏览依赖树也没有结果。