Skip to content
This repository was archived by the owner on Jun 5, 2025. It is now read-only.

Commit 8941135

Browse files
committed
fix: incorrect datetime format for strftime() in windows
The datetime format passed to Structlog's configuration inside setup_logging() in src/codegate/codegate_logging.py works on Linux but returns an error on Windows. Changed the datetime format so it works on Linux as well as Windows.
1 parent 05c2574 commit 8941135

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/codegate/codegate_logging.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ def setup_logging(
8282
# Adds log level and timestamp to log entries
8383
shared_processors = [
8484
structlog.processors.add_log_level,
85-
structlog.processors.TimeStamper(fmt="%Y-%m-%dT%H:%M:%S.%03dZ", utc=True),
85+
structlog.processors.TimeStamper(fmt="%Y-%m-%dT%H:%M:%S.%fZ", utc=True),
8686
add_origin,
8787
structlog.processors.CallsiteParameterAdder(
8888
[

0 commit comments

Comments
 (0)