Fork me on GitHub
#tools-deps
<
2018-11-25
>
dominicm10:11:34

I have an interesting conundrum in pack. I'm trying to suppress this output:

SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/home/dominic/.m2/repository/org/slf4j/slf4j-nop/1.6.2/slf4j-nop-1.6.2.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/home/dominic/.m2/repository/ch/qos/logback/logback-classic/1.2.3/logback-classic-1.2.3.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See  for an explanation.
SLF4J: Actual binding is of type [org.slf4j.helpers.NOPLoggerFactory]
Suppressing it for my projects is easy enough, I add exclusions to pack for slf4j-nop. However, on projects which don't already have their own logging stack, it then results in:
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See  for further details.
Which isn't a better result imo. The ideal is that the -main function's in pack would tell slf4j what to use if there's multiple bindings, suppressing the warning. But I don't see an obvious API for that. Anyone else got any good ideas?

borkdude12:11:00

Common mistake of mine:

$ clj -Srepro -Sdeps '{:deps {org.clojure/test.check {:mvn/release "RELEASE"}}}'
Error building classpath. nil
java.lang.NullPointerException
Maybe an error message could help here?