Mark python 3.5 support deprecated (#849)

* Mark python 3.5 unsupported

Fixes https://github.com/esphome/issues/issues/831

* Update .travis.yml

* Update typing dep
This commit is contained in:
Otto Winter 2019-11-12 21:44:28 +01:00
parent 6297395018
commit bfea6ca79b
No known key found for this signature in database
GPG Key ID: DB66C0BE6013F97E
3 changed files with 9 additions and 5 deletions

View File

@ -1,6 +1,6 @@
sudo: false
language: python
python: '3.5'
python: '3.6'
install: script/setup
cache:
directories:
@ -15,8 +15,8 @@ matrix:
- script/ci-custom.py
- flake8 esphome
- pylint esphome
- python: "3.5"
env: TARGET=Test3.5
- python: "3.6"
env: TARGET=Test3.6
script:
- esphome tests/test1.yaml compile
- esphome tests/test2.yaml compile

View File

@ -14,7 +14,7 @@ from esphome.const import CONF_BAUD_RATE, CONF_BROKER, CONF_LOGGER, CONF_OTA, \
CONF_PASSWORD, CONF_PORT, CONF_ESPHOME, CONF_PLATFORMIO_OPTIONS
from esphome.core import CORE, EsphomeError, coroutine, coroutine_with_priority
from esphome.helpers import color, indent
from esphome.py_compat import IS_PY2, safe_input
from esphome.py_compat import IS_PY2, safe_input, IS_PY3
from esphome.util import run_external_command, run_external_process, safe_print, list_yaml_files
_LOGGER = logging.getLogger(__name__)
@ -514,6 +514,10 @@ def run_esphome(argv):
_LOGGER.warning("You're using ESPHome with python 2. Support for python 2 is deprecated "
"and will be removed in 1.15.0. Please reinstall ESPHome with python 3.6 "
"or higher.")
elif IS_PY3 and sys.version_info < (3, 6, 0):
_LOGGER.warning("You're using ESPHome with python 3.5. Support for python 3.5 is "
"deprecated and will be removed in 1.15.0. Please reinstall ESPHome with "
"python 3.6 or higher.")
if args.command in PRE_CONFIG_ACTIONS:
try:

View File

@ -28,7 +28,7 @@ REQUIRES = [
'paho-mqtt==1.4.0',
'colorlog==4.0.2',
'tornado==5.1.1',
'typing>=3.6.6;python_version<"3.5"',
'typing>=3.6.6;python_version<"3.6"',
'protobuf==3.10.0',
'tzlocal==2.0.0',
'pytz==2019.3',