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

Error at begin on Windows 10 #167

Open
aayes89 opened this issue Apr 25, 2024 · 1 comment
Open

Error at begin on Windows 10 #167

aayes89 opened this issue Apr 25, 2024 · 1 comment

Comments

@aayes89
Copy link

aayes89 commented Apr 25, 2024

Shows errors in console when running project using NetBeans 21:

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

Taking a look, in the library, the referenced class is not present

@hiddenalpha
Copy link

hiddenalpha commented Apr 25, 2024

Works as designed as far as I see :)

This is slf4j informing that no logger is configured. More details about this behavior is documented in slf4j manual > libraries. It does not affect the working of jssc itself.

Cited from slf4j doc:

SLF4J version 1.6.0 and later will emit a single warning message about the absence of a binding and proceed to discard all log requests without further protest

If logging is wanted an app can add a logger implementation to the classpath and configure it according to the implementations documentation. Usually this is the way to go.

If no logs are wanted, we're already done. slf4j won't log anymore after this warning. To suppress this log too, an app can decide to add a so called no-op (no-operation) logger to the classpath. Such a no-op implementation is also listed at slf4j manual named slf4j-nop (eg available at mvnrepository.com or as jar).

But be aware: I personally am not a fan of no-op loggers, as they conceal potentially helpful error details. Only use one of those if suppressing of all logs really is the desired behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants