Open daronstinnett opened 8 years ago
Thanks. We'll look into it.
def log_information(self, should_log):
"""Log requests to stdout."""
if should_log:
try:
import http.client as http_client
except ImportError:
# Python 2
import httplib as http_client
http_client.HTTPConnection.debuglevel = 1
logging.basicConfig()
logging.getLogger().setLevel(logging.DEBUG)
requests_log = logging.getLogger("requests.packages.urllib3")
requests_log.setLevel(logging.DEBUG)
requests_log.propagate = True
@sankaet any ideas on how to fix this?
I noticed this because our tests created a client with logging=True, which caused subsequent tests in other applications to log requests to the console. Removing the logging=True kwarg solved the issue.