Closed tdudz closed 2 years ago
use_utc()
is now implemented in DeferredNow::format()
, while the rest of DeferredNow
only uses local time. Especially DeferredNow::now()
returns DateTime<Local>
.
If you change your code snippet from
now.now().format("%Y-%m-%d %H:%M:%S%.6f"),
to
now.format("%Y-%m-%d %H:%M:%S%.6f"),
then it works as intended.
The behavior is a bit unclear, though. I need to improve the docu.
And more: I just saw that DeferredNow::format_rfc3164()
is not going through format()
and thus ignores use_utc()
, which is of course a real bug.
thanks, that worked!
Version 0.24.1 fixes also the bug in deferredNow::format_rfc3164()
.
i updated my stack to
0.24.0
and even though i setuse_utc()
when making theLogger
handle, it still prints out using my local timei create the logger using the following:
i tested it by reverting to the previous
flexi_logger
version and the timestamps were UTC again. i suspect it might have something to do with the removal oftime
and re-addition ofchrono