From 3d8dbfcf7a48d4d16cc0564498dfa12b71a7ec66 Mon Sep 17 00:00:00 2001 From: Bertrand Bonnefoy-Claudet Date: Thu, 6 Jul 2017 15:15:59 +0200 Subject: [PATCH] Don't raise a warning if no envfile found The envfile is often used in development but not in production. The absence of envfile is normal and shouldn't lead to a warning. --- envparse.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/envparse.py b/envparse.py index e13b584..1bdda38 100644 --- a/envparse.py +++ b/envparse.py @@ -8,7 +8,6 @@ import os import re import shlex -import warnings try: import urllib.parse as urlparse except ImportError: @@ -192,7 +191,7 @@ def read_envfile(path=None, **overrides): Env.read_envfile(path, **overrides) else: # Reached top level directory. - warnings.warn('Could not any envfile.') + logger.debug('Could not find any envfile.') return logger.debug('Reading environment variables from: %s', path)