Skip to content

Commit

Permalink
Merge pull request #3217 from catalyst-cooperative/suppress_numba_logs
Browse files Browse the repository at this point in the history
Suppress excessive numba logs
  • Loading branch information
zaneselvans authored Jan 5, 2024
2 parents 10a7997 + cbc0c51 commit 68eed0d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/pudl/logging_helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ def configure_root_logger(logfile: str | None = None, loglevel: str = "INFO"):
logfile: Path to logfile or None.
loglevel: Level of detail at which to log, by default INFO.
"""
# Set numba log-level to warning to suppress excessive logs
numba_logger = logging.getLogger("numba")
numba_logger.setLevel(logging.WARNING)

logger = logging.getLogger("catalystcoop")
log_format = "%(asctime)s [%(levelname)8s] %(name)s:%(lineno)s %(message)s"
coloredlogs.install(fmt=log_format, level=loglevel, logger=logger)
Expand Down

0 comments on commit 68eed0d

Please sign in to comment.