Skip to content

Disable logging messages from Urllib and Requests libraries

If you use the urllib3 or requests library to perform web requests (for example for API calls) you may want to disable these logging messages:

Starting new HTTP connection (1): example.com
http://example.com:80 "GET / HTTP/1.1" 200 606

You can disable them by setting the logging level of those modules to warning:

[sc name=”src” url=”replaceMe” ]

Be First to Comment

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.