Skip to content

Commit

Permalink
ensure log payload is string
Browse files Browse the repository at this point in the history
  • Loading branch information
zacharyburnett committed May 1, 2024
1 parent f7a9c95 commit 9442431
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions jwst/associations/lib/log_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,10 @@ def __init__(self, *args, **kwargs):

def log(self, level, msg, *args, **kwargs):
if self.isEnabledFor(level):
# handle `pyplot.rc('test', usetex=True)``
if type(msg) == bytes:
msg = msg.decode()

for line in msg.split('\n'):
self._log(level, line, args, **kwargs)

Expand Down

0 comments on commit 9442431

Please sign in to comment.