From: Daniel Feldroy Date: Mon, 21 Sep 2020 18:13:53 +0000 (-0700) Subject: Remove twine and wheel from the testing requirements X-Git-Tag: 1.5.2~4 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=01f31396128761f41e7f0d6a8412cb7ac0aa20d3;p=cached-property.git Remove twine and wheel from the testing requirements --- diff --git a/requirements.txt b/requirements.txt index 90c6dfc..f414e94 100644 --- a/requirements.txt +++ b/requirements.txt @@ -4,5 +4,3 @@ flake8==3.8.3 pytest==6.0.2 pytest-cov==2.10.1 freezegun==1.0.0 -twine==3.2.0 -wheel==0.35.1 \ No newline at end of file diff --git a/setup.py b/setup.py index 6119fec..e5398c9 100755 --- a/setup.py +++ b/setup.py @@ -23,6 +23,11 @@ readme = read("README.rst") history = read("HISTORY.rst").replace(".. :changelog:", "") if sys.argv[-1] == "publish": + try: + import wheel + import twine + except (ImportError, ModuleNotFoundError): + raise ModuleNotFoundError('Run "pip install wheel twine"') os.system("python setup.py sdist bdist_wheel") os.system("twine upload dist/*") os.system("git tag -a %s -m 'version %s'" % (__version__, __version__))