Merge branch 'develop' into feat/short

This commit is contained in:
Matthias 2022-03-30 07:09:41 +02:00
commit dafc2bf361
8 changed files with 35 additions and 26 deletions

View File

@ -31,14 +31,14 @@ jobs:
python-version: ${{ matrix.python-version }}
- name: Cache_dependencies
uses: actions/cache@v2
uses: actions/cache@v3
id: cache
with:
path: ~/dependencies/
key: ${{ runner.os }}-dependencies
- name: pip cache (linux)
uses: actions/cache@v2
uses: actions/cache@v3
if: runner.os == 'Linux'
with:
path: ~/.cache/pip
@ -126,14 +126,14 @@ jobs:
python-version: ${{ matrix.python-version }}
- name: Cache_dependencies
uses: actions/cache@v2
uses: actions/cache@v3
id: cache
with:
path: ~/dependencies/
key: ${{ runner.os }}-dependencies
- name: pip cache (macOS)
uses: actions/cache@v2
uses: actions/cache@v3
if: runner.os == 'macOS'
with:
path: ~/Library/Caches/pip
@ -218,7 +218,7 @@ jobs:
python-version: ${{ matrix.python-version }}
- name: Pip cache (Windows)
uses: actions/cache@preview
uses: actions/cache@v3
with:
path: ~\AppData\Local\pip\Cache
key: ${{ matrix.os }}-${{ matrix.python-version }}-pip

View File

@ -10,7 +10,7 @@ jobs:
steps:
- uses: actions/checkout@v3
- name: Docker Hub Description
uses: peter-evans/dockerhub-description@v2.4.3
uses: peter-evans/dockerhub-description@v3
env:
DOCKERHUB_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKERHUB_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}

View File

@ -1,5 +1,5 @@
mkdocs==1.2.3
mkdocs-material==8.2.5
mkdocs==1.3.0
mkdocs-material==8.2.8
mdx_truly_sane_lists==1.2
pymdown-extensions==9.3
jinja2==3.0.3
jinja2==3.1.1

View File

@ -25,6 +25,7 @@ class Kucoin(Exchange):
"l2_limit_range_required": False,
"order_time_in_force": ['gtc', 'fok', 'ioc'],
"time_in_force_parameter": "timeInForce",
"ohlcv_candle_limit": 1500,
}
def stoploss_adjust(self, stop_loss: float, order: Dict, side: str) -> bool:

View File

@ -6,9 +6,9 @@
coveralls==3.3.1
flake8==4.0.1
flake8-tidy-imports==4.6.0
mypy==0.941
mypy==0.942
pytest==7.1.1
pytest-asyncio==0.18.2
pytest-asyncio==0.18.3
pytest-cov==3.0.0
pytest-mock==3.7.0
pytest-random-order==1.0.4
@ -22,7 +22,7 @@ nbconvert==6.4.4
# mypy types
types-cachetools==5.0.0
types-filelock==3.2.5
types-requests==2.27.14
types-requests==2.27.15
types-tabulate==0.8.6
# Extensions to datetime library

View File

@ -2,7 +2,7 @@ numpy==1.22.3
pandas==1.4.1
pandas-ta==0.3.14b
ccxt==1.77.29
ccxt==1.77.45
# Pin cryptography for now due to rust build errors with piwheels
cryptography==36.0.2
aiohttp==3.8.1
@ -17,7 +17,7 @@ TA-Lib==0.4.24
technical==1.3.0
tabulate==0.8.9
pycoingecko==2.2.0
jinja2==3.0.3
jinja2==3.1.1
tables==3.7.0
blosc==1.10.6

View File

@ -1612,8 +1612,8 @@ def limit_buy_order_open():
'type': 'limit',
'side': 'buy',
'symbol': 'mocked',
'timestamp': arrow.utcnow().int_timestamp * 1000,
'datetime': arrow.utcnow().isoformat(),
'timestamp': arrow.utcnow().int_timestamp,
'price': 0.00001099,
'amount': 90.99181073,
'filled': 0.0,
@ -1639,6 +1639,7 @@ def market_buy_order():
'type': 'market',
'side': 'buy',
'symbol': 'mocked',
'timestamp': arrow.utcnow().int_timestamp * 1000,
'datetime': arrow.utcnow().isoformat(),
'price': 0.00004099,
'amount': 91.99181073,
@ -1655,6 +1656,7 @@ def market_sell_order():
'type': 'market',
'side': 'sell',
'symbol': 'mocked',
'timestamp': arrow.utcnow().int_timestamp * 1000,
'datetime': arrow.utcnow().isoformat(),
'price': 0.00004173,
'amount': 91.99181073,
@ -1671,7 +1673,8 @@ def limit_buy_order_old():
'type': 'limit',
'side': 'buy',
'symbol': 'mocked',
'datetime': str(arrow.utcnow().shift(minutes=-601).datetime),
'datetime': arrow.utcnow().shift(minutes=-601).isoformat(),
'timestamp': arrow.utcnow().shift(minutes=-601).int_timestamp * 1000,
'price': 0.00001099,
'amount': 90.99181073,
'filled': 0.0,
@ -1687,6 +1690,7 @@ def limit_sell_order_old():
'type': 'limit',
'side': 'sell',
'symbol': 'ETH/BTC',
'timestamp': arrow.utcnow().shift(minutes=-601).int_timestamp * 1000,
'datetime': arrow.utcnow().shift(minutes=-601).isoformat(),
'price': 0.00001099,
'amount': 90.99181073,
@ -1703,6 +1707,7 @@ def limit_buy_order_old_partial():
'type': 'limit',
'side': 'buy',
'symbol': 'ETH/BTC',
'timestamp': arrow.utcnow().shift(minutes=-601).int_timestamp * 1000,
'datetime': arrow.utcnow().shift(minutes=-601).isoformat(),
'price': 0.00001099,
'amount': 90.99181073,
@ -1732,7 +1737,7 @@ def limit_buy_order_canceled_empty(request):
'info': {},
'id': '1234512345',
'clientOrderId': None,
'timestamp': arrow.utcnow().shift(minutes=-601).int_timestamp,
'timestamp': arrow.utcnow().shift(minutes=-601).int_timestamp * 1000,
'datetime': arrow.utcnow().shift(minutes=-601).isoformat(),
'lastTradeTimestamp': None,
'symbol': 'LTC/USDT',
@ -1753,7 +1758,7 @@ def limit_buy_order_canceled_empty(request):
'info': {},
'id': 'AZNPFF-4AC4N-7MKTAT',
'clientOrderId': None,
'timestamp': arrow.utcnow().shift(minutes=-601).int_timestamp,
'timestamp': arrow.utcnow().shift(minutes=-601).int_timestamp * 1000,
'datetime': arrow.utcnow().shift(minutes=-601).isoformat(),
'lastTradeTimestamp': None,
'status': 'canceled',
@ -1774,7 +1779,7 @@ def limit_buy_order_canceled_empty(request):
'info': {},
'id': '1234512345',
'clientOrderId': 'alb1234123',
'timestamp': arrow.utcnow().shift(minutes=-601).int_timestamp,
'timestamp': arrow.utcnow().shift(minutes=-601).int_timestamp * 1000,
'datetime': arrow.utcnow().shift(minutes=-601).isoformat(),
'lastTradeTimestamp': None,
'symbol': 'LTC/USDT',
@ -1795,7 +1800,7 @@ def limit_buy_order_canceled_empty(request):
'info': {},
'id': '1234512345',
'clientOrderId': 'alb1234123',
'timestamp': arrow.utcnow().shift(minutes=-601).int_timestamp,
'timestamp': arrow.utcnow().shift(minutes=-601).int_timestamp * 1000,
'datetime': arrow.utcnow().shift(minutes=-601).isoformat(),
'lastTradeTimestamp': None,
'symbol': 'LTC/USDT',
@ -1821,7 +1826,7 @@ def limit_sell_order_open():
'side': 'sell',
'symbol': 'mocked',
'datetime': arrow.utcnow().isoformat(),
'timestamp': arrow.utcnow().int_timestamp,
'timestamp': arrow.utcnow().int_timestamp * 1000,
'price': 0.00001173,
'amount': 90.99181073,
'filled': 0.0,
@ -1987,7 +1992,7 @@ def tickers():
'BLK/BTC': {
'symbol': 'BLK/BTC',
'timestamp': 1522014806072,
'datetime': '2018-03-25T21:53:26.720Z',
'datetime': '2018-03-25T21:53:26.072Z',
'high': 0.007745,
'low': 0.007512,
'bid': 0.007729,
@ -2483,7 +2488,8 @@ def buy_order_fee():
'type': 'limit',
'side': 'buy',
'symbol': 'mocked',
'datetime': str(arrow.utcnow().shift(minutes=-601).datetime),
'timestamp': arrow.utcnow().shift(minutes=-601).int_timestamp * 1000,
'datetime': arrow.utcnow().shift(minutes=-601).isoformat(),
'price': 0.245441,
'amount': 8.0,
'cost': 1.963528,
@ -2801,7 +2807,7 @@ def limit_buy_order_usdt_open():
'side': 'buy',
'symbol': 'mocked',
'datetime': arrow.utcnow().isoformat(),
'timestamp': arrow.utcnow().int_timestamp,
'timestamp': arrow.utcnow().int_timestamp * 1000,
'price': 2.00,
'amount': 30.0,
'filled': 0.0,
@ -2828,7 +2834,7 @@ def limit_sell_order_usdt_open():
'side': 'sell',
'symbol': 'mocked',
'datetime': arrow.utcnow().isoformat(),
'timestamp': arrow.utcnow().int_timestamp,
'timestamp': arrow.utcnow().int_timestamp * 1000,
'price': 2.20,
'amount': 30.0,
'cost': 66.0,
@ -2854,6 +2860,7 @@ def market_buy_order_usdt():
'type': 'market',
'side': 'buy',
'symbol': 'mocked',
'timestamp': arrow.utcnow().int_timestamp * 1000,
'datetime': arrow.utcnow().isoformat(),
'price': 2.00,
'amount': 30.0,
@ -2910,6 +2917,7 @@ def market_sell_order_usdt():
'type': 'market',
'side': 'sell',
'symbol': 'mocked',
'timestamp': arrow.utcnow().int_timestamp * 1000,
'datetime': arrow.utcnow().isoformat(),
'price': 2.20,
'amount': 30.0,

View File

@ -1247,7 +1247,7 @@ def test_create_order(default_conf, mocker, side, ordertype, rate, marketprice,
ordertype=ordertype,
side=side,
amount=1,
rate=200,
rate=rate,
leverage=1.0
)