Skip to content

Commit

Permalink
use env var to set shared logging level when sampling
Browse files Browse the repository at this point in the history
  • Loading branch information
henryaddison committed Feb 28, 2024
1 parent 6e7ef98 commit 03ebfec
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions bin/predict.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,10 @@
load_dotenv() # take environment variables from .env.

logging.basicConfig(
level=logging.INFO,
level=os.environ.get("LOG_LEVEL", "INFO").upper(),
format="%(levelname)s - %(filename)s - %(asctime)s - %(message)s",
)
logger = logging.getLogger()
logger.setLevel(os.environ.get("LOG_LEVEL", "INFO").upper())

app = typer.Typer()

Expand Down

0 comments on commit 03ebfec

Please sign in to comment.