* Hotfix for recently updated Python Requests package (2.16.0)

This commit is contained in:
Ivan Kravets
2017-05-27 12:55:46 +03:00
parent df226df87d
commit 49b2e7303e
2 changed files with 9 additions and 5 deletions

View File

@ -4,6 +4,11 @@ Release Notes
PlatformIO 3.0
--------------
3.3.1 (2017-05-27)
~~~~~~~~~~~~~~~~~~
* Hotfix for recently updated Python Requests package (2.16.0)
3.3.0 (2017-03-27)
~~~~~~~~~~~~~~~~~~

View File

@ -89,11 +89,10 @@ def main():
# https://urllib3.readthedocs.org
# /en/latest/security.html#insecureplatformwarning
try:
requests.packages.urllib3.disable_warnings()
except AttributeError:
raise exception.PlatformioException(
"Invalid installation of Python `requests` package`. See "
"< https://github.com/platformio/platformio-core/issues/252 >")
import urllib3
urllib3.disable_warnings()
except (AttributeError, ImportError):
pass
# handle PLATFORMIO_FORCE_COLOR
if str(getenv("PLATFORMIO_FORCE_COLOR", "")).lower() == "true":