forked from iotaledger/iota.py
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[iotaledger#145] Reformat setup.py for PEP-8.
- Loading branch information
1 parent
8f804e6
commit 43f5219
Showing
1 changed file
with
68 additions
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,103 +5,99 @@ | |
from __future__ import absolute_import, division, print_function | ||
|
||
from codecs import StreamReader, open | ||
from distutils.version import LooseVersion | ||
|
||
import setuptools | ||
from setuptools import find_packages, setup | ||
|
||
|
||
## | ||
# Because of the way PyOTA declares its dependencies, it requires a | ||
# more recent version of setuptools. | ||
# https://www.python.org/dev/peps/pep-0508/#environment-markers | ||
from distutils.version import LooseVersion | ||
if LooseVersion(setuptools.__version__) < LooseVersion('20.5'): | ||
import sys | ||
sys.exit('Installation failed: Upgrade setuptools to version 20.5 or later') | ||
|
||
sys.exit('Installation failed: Upgrade setuptools to version 20.5 or later') | ||
|
||
## | ||
# Load long description for PyPi. | ||
with open('README.rst', 'r', 'utf-8') as f: # type: StreamReader | ||
long_description = f.read() | ||
|
||
# Load long description for PyPI. | ||
with open('README.rst', 'r', 'utf-8') as f: # type: StreamReader | ||
long_description = f.read() | ||
|
||
## | ||
# Declare test dependencies separately, so that they can be installed | ||
# either automatically (``python setup.py test``) or manually | ||
# (``pip install -e .[test-runner]``). | ||
tests_require = [ | ||
'mock; python_version < "3.0"', | ||
'nose', | ||
'mock; python_version < "3.0"', | ||
'nose', | ||
] | ||
|
||
|
||
## | ||
# Off we go! | ||
# noinspection SpellCheckingInspection | ||
setup( | ||
name = 'PyOTA', | ||
description = 'IOTA API library for Python', | ||
url = 'https://github.com/iotaledger/iota.lib.py', | ||
version = '2.0.6', | ||
|
||
long_description = long_description, | ||
|
||
packages = | ||
find_packages('.', exclude=( | ||
'examples', 'examples.*', | ||
'test', 'test.*', | ||
setuptools.setup( | ||
name='PyOTA', | ||
description='IOTA API library for Python', | ||
url='https://github.com/iotaledger/iota.lib.py', | ||
version='2.0.6', | ||
|
||
long_description=long_description, | ||
|
||
packages=setuptools.find_packages('.', exclude=( | ||
'examples', 'examples.*', | ||
'test', 'test.*', | ||
)), | ||
|
||
include_package_data = True, | ||
include_package_data=True, | ||
|
||
# http://python-packaging.readthedocs.io/en/latest/command-line-scripts.html#the-console-scripts-entry-point | ||
entry_points={ | ||
'console_scripts': [ | ||
'pyota-cli=iota.bin.repl:main', | ||
], | ||
}, | ||
|
||
install_requires=[ | ||
'filters', | ||
'pysha3', | ||
|
||
# ``security`` extra wasn't introduced until 2.4.1 | ||
# http://docs.python-requests.org/en/latest/community/updates/#id35 | ||
'requests[security] >= 2.4.1', | ||
|
||
# http://python-packaging.readthedocs.io/en/latest/command-line-scripts.html#the-console-scripts-entry-point | ||
entry_points = { | ||
'console_scripts': [ | ||
'pyota-cli=iota.bin.repl:main', | ||
'six', | ||
'typing; python_version < "3.0"', | ||
], | ||
}, | ||
|
||
install_requires = [ | ||
'filters', | ||
'pysha3', | ||
|
||
# ``security`` extra wasn't introduced until 2.4.1 | ||
# http://docs.python-requests.org/en/latest/community/updates/#id35 | ||
'requests[security] >= 2.4.1', | ||
|
||
'six', | ||
'typing; python_version < "3.0"', | ||
], | ||
|
||
extras_require = { | ||
'ccurl': ['pyota-ccurl'], | ||
'docs-builder': ['sphinx', 'sphinx_rtd_theme'], | ||
'test-runner': ['detox'] + tests_require, | ||
}, | ||
|
||
test_suite = 'test', | ||
test_loader = 'nose.loader:TestLoader', | ||
tests_require = tests_require, | ||
|
||
license = 'MIT', | ||
|
||
classifiers = [ | ||
'Development Status :: 5 - Production/Stable', | ||
'Intended Audience :: Developers', | ||
'License :: OSI Approved :: MIT License', | ||
'Programming Language :: Python :: 2', | ||
'Programming Language :: Python :: 2.7', | ||
'Programming Language :: Python :: 3', | ||
'Programming Language :: Python :: 3.5', | ||
'Programming Language :: Python :: 3.6', | ||
'Topic :: Software Development :: Libraries :: Python Modules', | ||
], | ||
|
||
keywords = | ||
'iota,tangle,iot,internet of things,api,library,cryptocurrency,' | ||
'balanced ternary', | ||
|
||
author = 'Phoenix Zerin', | ||
author_email = '[email protected]', | ||
|
||
extras_require={ | ||
'ccurl': ['pyota-ccurl'], | ||
'docs-builder': ['sphinx', 'sphinx_rtd_theme'], | ||
'test-runner': ['detox'] + tests_require, | ||
}, | ||
|
||
test_suite='test', | ||
test_loader='nose.loader:TestLoader', | ||
tests_require=tests_require, | ||
|
||
license='MIT', | ||
|
||
classifiers=[ | ||
'Development Status :: 5 - Production/Stable', | ||
'Intended Audience :: Developers', | ||
'License :: OSI Approved :: MIT License', | ||
'Programming Language :: Python :: 2', | ||
'Programming Language :: Python :: 2.7', | ||
'Programming Language :: Python :: 3', | ||
'Programming Language :: Python :: 3.5', | ||
'Programming Language :: Python :: 3.6', | ||
'Topic :: Software Development :: Libraries :: Python Modules', | ||
], | ||
|
||
keywords=( | ||
'iota,tangle,iot,internet of things,api,library,cryptocurrency,' | ||
'balanced ternary' | ||
), | ||
|
||
author='Phoenix Zerin', | ||
author_email='[email protected]', | ||
) |