mirror of
https://github.com/bigchaindb/bigchaindb.git
synced 2024-10-13 13:34:05 +00:00
Merge branch 'more-explicit-error-reporting-for-pkg_resources'
This commit is contained in:
commit
b1101747c0
17
setup.py
17
setup.py
@ -6,11 +6,28 @@ For full docs visit https://bigchaindb.readthedocs.org
|
|||||||
"""
|
"""
|
||||||
from setuptools import setup, find_packages
|
from setuptools import setup, find_packages
|
||||||
|
|
||||||
|
|
||||||
# get the version
|
# get the version
|
||||||
version = {}
|
version = {}
|
||||||
with open('bigchaindb/version.py') as fp:
|
with open('bigchaindb/version.py') as fp:
|
||||||
exec(fp.read(), version)
|
exec(fp.read(), version)
|
||||||
|
|
||||||
|
|
||||||
|
# check if setuptools is up to date
|
||||||
|
def check_setuptools_features():
|
||||||
|
import pkg_resources
|
||||||
|
try:
|
||||||
|
list(pkg_resources.parse_requirements('foo~=1.0'))
|
||||||
|
except ValueError:
|
||||||
|
exit('Your Python distribution comes with an incompatible version '
|
||||||
|
'of `setuptools`. Please run:\n'
|
||||||
|
' $ pip3 install --upgrade setuptools\n'
|
||||||
|
'and then run this command again')
|
||||||
|
|
||||||
|
|
||||||
|
check_setuptools_features()
|
||||||
|
|
||||||
|
|
||||||
tests_require = [
|
tests_require = [
|
||||||
'pytest',
|
'pytest',
|
||||||
'coverage',
|
'coverage',
|
||||||
|
Loading…
x
Reference in New Issue
Block a user