Disable InsecureRequestWarning if SSL verify is False
If checking of HTTPS validity is disable, turn off the warning that it has been disabled since we have done so explicitly.
This commit is contained in:
parent
00f4bf26a9
commit
7b0cc2d2a9
@ -59,6 +59,10 @@ sess.verify = False # '/path/to/certfile'
|
||||
# If verify is set to a path to a directory,
|
||||
# the directory must have been processed using the c_rehash utility supplied
|
||||
# with OpenSSL.
|
||||
if sess.verify is False:
|
||||
# Disable the warning that the request is insecure, we know that...
|
||||
import urllib3
|
||||
urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)
|
||||
|
||||
SELECTOR = ['stream', 'allStreams']
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user