Skip to content

Commit

Permalink
Used the minimum python version defined in homeassistant.const.
Browse files Browse the repository at this point in the history
  • Loading branch information
pelson committed Feb 7, 2018
1 parent f6f96b6 commit 74c5dd7
Showing 1 changed file with 13 additions and 5 deletions.
18 changes: 13 additions & 5 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,16 @@
"""Home Assistant setup script."""
import os
from setuptools import setup, find_packages
import sys

import homeassistant.const as hass_const

from homeassistant.const import __version__

PROJECT_NAME = 'Home Assistant'
PROJECT_PACKAGE_NAME = 'homeassistant'
PROJECT_LICENSE = 'Apache License 2.0'
PROJECT_AUTHOR = 'The Home Assistant Authors'
PROJECT_COPYRIGHT = ' 2013-2017, {}'.format(PROJECT_AUTHOR)
PROJECT_COPYRIGHT = ' 2013-2018, {}'.format(PROJECT_AUTHOR)
PROJECT_URL = 'https://home-assistant.io/'
PROJECT_EMAIL = 'hello@home-assistant.io'
PROJECT_DESCRIPTION = ('Open-source home automation platform '
Expand Down Expand Up @@ -41,7 +43,7 @@


HERE = os.path.abspath(os.path.dirname(__file__))
DOWNLOAD_URL = '{}/archive/{}.zip'.format(GITHUB_URL, __version__)
DOWNLOAD_URL = '{}/archive/{}.zip'.format(GITHUB_URL, hass_const.__version__)

PACKAGES = find_packages(exclude=['tests', 'tests.*'])

Expand All @@ -61,9 +63,15 @@
'certifi>=2017.4.17',
]

MIN_PY_VERSION = '.'.join(map(
str,
hass_const.REQUIRED_PYTHON_VER_WIN
if sys.platform.startswith('win')
else hass_const.REQUIRED_PYTHON_VER))

setup(
name=PROJECT_PACKAGE_NAME,
version=__version__,
version=hass_const.__version__,
license=PROJECT_LICENSE,
url=PROJECT_URL,
download_url=DOWNLOAD_URL,
Expand All @@ -75,7 +83,7 @@
zip_safe=False,
platforms='any',
install_requires=REQUIRES,
python_requires=">=3.4",
python_requires='>={}'.format(MIN_PY_VERSION),
test_suite='tests',
keywords=['home', 'automation'],
entry_points={
Expand Down

0 comments on commit 74c5dd7

Please sign in to comment.