Get the desired version of chiavdf out of setup.py.

This commit is contained in:
Richard Kiss 2020-03-31 17:39:42 -07:00
parent 155d14aff9
commit 4e785969b5
2 changed files with 11 additions and 4 deletions

View File

@ -1,5 +1,6 @@
THE_PATH=`python -c 'import pkg_resources; print( pkg_resources.get_distribution("chiavdf").location)' 2> /dev/null`/vdf_client
CHIAVDF_VERSION=`python -c 'from setup import dependencies; t = [_ for _ in dependencies if _.startswith("chiavdf")][0]; print(t)'`
if [ -e $THE_PATH ]
then
@ -9,8 +10,8 @@ else
if [ -e venv/bin/python ]
then
echo "installing chiavdf from source"
echo venv/bin/python -m pip install --force --no-binary chiavdf chiavdf==0.12.2
venv/bin/python -m pip install --force --no-binary chiavdf chiavdf==0.12.2
echo venv/bin/python -m pip install --force --no-binary chiavdf $CHIAVDF_VERSION
venv/bin/python -m pip install --force --no-binary chiavdf $CHIAVDF_VERSION
else
echo "no venv created yet, please run install.sh"
fi

View File

@ -36,7 +36,7 @@ dev_dependencies = [
"pytest-asyncio",
]
setup(
kwargs = dict(
name="chia-blockchain",
author="Mariano Sorgente",
author_email="mariano@chia.net",
@ -46,7 +46,9 @@ setup(
keywords="chia blockchain node",
install_requires=dependencies,
setup_requires=["setuptools_scm"],
extras_require=dict(uvloop=["uvloop"], dev=dev_dependencies, upnp=upnp_dependencies),
extras_require=dict(
uvloop=["uvloop"], dev=dev_dependencies, upnp=upnp_dependencies,
),
packages=[
"src",
"src.cmds",
@ -93,3 +95,7 @@ setup(
long_description=open("README.md").read(),
zip_safe=False,
)
if __name__ == "__main__":
setup(**kwargs)