Need help with org.slf4j.impl.StaticLoggerBinder

When I run a large test suite I see the following message printed.

SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See for further details.

The warnings seem to be coming from a Java library that something is indirectly using.
When I look at the web page, SLF4J Error Codes, it gives me advice that I don’t understand.

It basically says I need to put one (and only one) of *slf4j-nop.jar* *slf4j-simple.jar* , *slf4j-log4j12.jar* , *slf4j-jdk14.jar* or *logback-classic.jar* in my class path.

How should I do that? Is that something I need to put in my build.sbt file?

Further in the web page it says

If you are responsible for packaging an application and do not care about logging, then placing slf4j-nop.jar on the class path of your application will get rid of this warning message.

It sounds like what I need to do. How can I do it?

I suppose this must be part of the project set up not just my individually?

Yes, just like any other dependency.
Which one depends on what you want, you may just add the slf4j-nop one if you don’t care about logging, or you may add a real logging implementation; logback being the most common AFAIK.

So do I need to add something to the libraryDependencies variable?

Yikes!!! this looks complicated. scala - sbt exclusion slf4j not working - Stack Overflow

Yeah, just add logback and call it a day, everything that comes from Java is cursed in some way or another.

libraryDependencies += "ch.qos.logback" % "logback-classic" % "1.2.10"
1 Like

related [SOLVED] Slf4j Logger neither print to console nor file

Seems like it really wants to notify us that it is working correctly.

15:46:38.689 [pool-7-thread-6-ScalaTest-running-RteDfaTestSuite] INFO org.reflections.Reflections - Reflections took 1130 ms to scan 47 urls, producing 4486 keys and 24931 values