From 8dd8addd3aeadfd652f65a3a141491e263dcd79b Mon Sep 17 00:00:00 2001 From: Matthias Date: Mon, 29 Jul 2019 20:52:38 +0200 Subject: [PATCH 1/4] Sort requirements-dev file --- requirements-dev.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/requirements-dev.txt b/requirements-dev.txt index 946d63039..f54b38a57 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -2,13 +2,13 @@ -r requirements.txt -r requirements-plot.txt +coveralls==1.8.1 flake8==3.7.8 flake8-type-annotations==0.1.0 flake8-tidy-imports==2.0.0 +mypy==0.720 pytest==5.0.1 -pytest-mock==1.10.4 pytest-asyncio==0.10.0 pytest-cov==2.7.1 +pytest-mock==1.10.4 pytest-random-order==1.0.4 -coveralls==1.8.1 -mypy==0.720 From 7bea0007c7b6ef253a5e7903728ac556f5c2e0e1 Mon Sep 17 00:00:00 2001 From: Matthias Date: Mon, 29 Jul 2019 20:53:26 +0200 Subject: [PATCH 2/4] Allow installing via submodules freqtrade can be installed using `pip install -e .[all]` to include all dependencies --- setup.py | 39 ++++++++++++++++++++++++++++++++++----- 1 file changed, 34 insertions(+), 5 deletions(-) diff --git a/setup.py b/setup.py index ca2f81d1f..1ae395295 100644 --- a/setup.py +++ b/setup.py @@ -8,6 +8,24 @@ if version_info.major == 3 and version_info.minor < 6 or \ from freqtrade import __version__ +# Requirements used for submodules +api = ['flask'] +plot = ['plotly>=4.0'] + +develop = [ + 'coveralls', + 'flake8', + 'flake8-type-annotations', + 'flake8-tidy-imports', + 'mypy', + 'pytest', + 'pytest-asyncio', + 'pytest-cov', + 'pytest-mock', + 'pytest-random-order', +] + +all_extra = api + plot + develop setup(name='freqtrade', version=__version__, @@ -20,26 +38,37 @@ setup(name='freqtrade', setup_requires=['pytest-runner', 'numpy'], tests_require=['pytest', 'pytest-mock', 'pytest-cov'], install_requires=[ - 'ccxt', + # from requirements-common.txt + 'ccxt>=1.18', 'SQLAlchemy', 'python-telegram-bot', 'arrow', + 'cachetools', 'requests', 'urllib3', 'wrapt', - 'pandas', 'scikit-learn', - 'scipy', 'joblib', 'jsonschema', 'TA-Lib', 'tabulate', - 'cachetools', 'coinmarketcap', 'scikit-optimize', + 'filelock', + 'py_find_1st', 'python-rapidjson', - 'py_find_1st' + 'sdnotify', + # from requirements.txt + 'numpy', + 'pandas', + 'scipy', ], + extras_require={ + 'api': api, + 'dev': develop, + 'plot': plot, + 'all': all_extra, + }, include_package_data=True, zip_safe=False, entry_points={ From f825e81d0eba06b58adc721715d7bbc545413ee4 Mon Sep 17 00:00:00 2001 From: Matthias Date: Mon, 29 Jul 2019 20:54:35 +0200 Subject: [PATCH 3/4] developers need all dependencies! --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 1ae395295..202e3fd0d 100644 --- a/setup.py +++ b/setup.py @@ -65,7 +65,7 @@ setup(name='freqtrade', ], extras_require={ 'api': api, - 'dev': develop, + 'dev': all_extra, 'plot': plot, 'all': all_extra, }, From 59caff8fb1d49bf26b29cb3855354d0eed7d2aa9 Mon Sep 17 00:00:00 2001 From: Matthias Date: Mon, 29 Jul 2019 20:57:57 +0200 Subject: [PATCH 4/4] UPdate developer docs --- docs/developer.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/developer.md b/docs/developer.md index f58e0597d..2895db7e8 100644 --- a/docs/developer.md +++ b/docs/developer.md @@ -12,8 +12,8 @@ Special fields for the documentation (like Note boxes, ...) can be found [here]( ## Developer setup -To configure a development environment, use best use the `setup.sh` script and answer "y" when asked "Do you want to install dependencies for dev [y/N]? ". -Alternatively (if your system is not supported by the setup.sh script), follow the manual installation process and run `pip3 install -r requirements-dev.txt`. +To configure a development environment, best use the `setup.sh` script and answer "y" when asked "Do you want to install dependencies for dev [y/N]? ". +Alternatively (if your system is not supported by the setup.sh script), follow the manual installation process and run `pip3 install -e .[all]`. This will install all required tools for development, including `pytest`, `flake8`, `mypy`, and `coveralls`.