Skip to content

Commit

Permalink
feat: add rich logging format string
Browse files Browse the repository at this point in the history
  • Loading branch information
kentbull committed Jan 30, 2025
1 parent 610ab78 commit d41d53a
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/keri/help/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,15 @@ def trace(self, message, *args, **kwargs):
# want help.ogler always defined by default
ogler = ogling.initOgler(prefix='keri', syslogged=False) # inits once only on first import

# set log formatters with detailed log output
logFmt = "%(asctime)s [keri] %(module)s.%(funcName)s-%(lineno)d %(levelname)-8s %(message)s"
formatter = logging.Formatter(logFmt)

ch = logging.StreamHandler()
ch.setFormatter(formatter)
ogler.baseConsoleHandler = ch
ogler.baseFormatter = formatter

ogler.reopen(headDirPath=ogler.headDirPath)

from .helping import nowIso8601, toIso8601, fromIso8601

0 comments on commit d41d53a

Please sign in to comment.