Skip to content

Commit

Permalink
fix: propagate log level to aws services
Browse files Browse the repository at this point in the history
  • Loading branch information
Chuyang Deng committed Sep 20, 2020
1 parent ecd9abc commit 3400631
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/sagemaker_training/logging_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ def configure_logger(level, log_format="%(asctime)s %(name)-12s %(levelname)-8s
logging.basicConfig(format=log_format, level=level)

if level >= logging.INFO:
logging.getLogger("boto3").setLevel(logging.INFO)
logging.getLogger("s3transfer").setLevel(logging.INFO)
logging.getLogger("botocore").setLevel(logging.WARN)
logging.getLogger("boto3").setLevel(level)
logging.getLogger("s3transfer").setLevel(level)
logging.getLogger("botocore").setLevel(level)


def log_script_invocation(cmd, env_vars, logger=None):
Expand Down

0 comments on commit 3400631

Please sign in to comment.