-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
Multisink with localisation #3305
Comments
The default value of the global log level is spdlog/include/spdlog/details/registry.h Line 114 in 276ee5f
|
Yeah i was doing it but in wrong place... But still i do not understand why returning a pointer and dereferencing it then pushing to SPDLOG_TRACE give me error which i posted. I mean, i did exactly what was in wiki just wrapping it into static function from class and dereferenced pointer instead of direct object. Im trying to make multisink logger for default logger with possibility to disable/enable console logs at compile time so i can have console logs when debugging some part and file always. |
This is because the argument is wrong. - SPDLOG_TRACE(*cLogs::getLogger(), "Starting game MACRO...");
+ SPDLOG_LOGGER_TRACE(*cLogs::getLogger(), "Starting game MACRO..."); spdlog/include/spdlog/spdlog.h Lines 286 to 301 in 276ee5f
|
I think i got it working, thanks |
Hello, i can't find discord or any other place where i can ask so i choose this place.
I created singleton where i'm keeping my sinks and logger, i want to display logs from code into files and console if console is enabled but i have 3 problems.
Basically all code which is involved is that:
I followed wiki and guides and in theory it should work but does not. Line with parsing logger throwing error, 1st log is not displayed or saved into file.
Output without parsing is
Log 1
Log 2
Log 3
...
Log 4
[2025-01-01 11:29:30.441] [logger] [info] Starting game...
Log 5
Log 6
So 1st log do not work when 2nd with parsing just give error.
The text was updated successfully, but these errors were encountered: