MCPcopy Create free account
hub / github.com/Tron521/codex-console-temp / formatTime

Method formatTime

src/core/utils.py:31–35  ·  view source on GitHub ↗
(self, record, datefmt=None)

Source from the content-addressed store, hash-verified

29 """
30
31 def formatTime(self, record, datefmt=None): # noqa: N802
32 dt = datetime.fromtimestamp(record.created, tz=timezone.utc).astimezone(SHANGHAI_TZ)
33 if datefmt:
34 return dt.strftime(datefmt)
35 return dt.strftime("%Y-%m-%d %H:%M:%S")
36
37
38def setup_logging(

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected