Great work with the library! Is it still in use/active development?
I found a couple bugs in today's testing, I'll list them below rather than opening multiple issues:
- Running commands in terminal, for example
python3 ./bmcli.py -a 0.001 0.005 25, constantly reports lag errors as such:
[+] bitmex is lagging 86399 second(s)
[+] Websocket is lagging 86399 seconds.
This is exactly 24h so I'm assuming that the ticker['timestamp'] is reporting set to 1 day in the future? I didn't do extensive testing yet, just commented everything below if self.lag >= 30: in bitmex_ws.py.
2.1) I'm running into some issues with the autostop function (great idea BTW). The trailing stop part seems to work fine, but the stop loss does not. More specifically, after running python3 ./bmcli.py -a 0.001 0.001 20 and the stop loss threshold being reached, this is the output:
[+] [ Params: 0.001|0.001 | 25.0] | [ High: 36924|Diff: 26.91399999999703 ]
[+] [ Unrealized PNL: -5e-08 | Realized PNL: -3.7e-07 | Balance: xxxxxxxx]
[+] [ 2021-01-16 15:29:08, Position: 1 | Entry Price: 36914.0 ]
[+] quote {'symbol': 'XBTUSD', 'id': 8796313950, 'side': 'Sell', 'size': 730214, 'price': 36860.5}
[!] Error: 'bid'
The script exits immediately after that and does not execute any sales.
2.2) The second, minor issue I observed with the autostop function is that the script doesn't terminate when autostop function successfully closes a position using the trailing stop and I need to use Ctrl+C combination to escape manually.
- The addition of SyBrain is interesting, but I've been running into the same problem as described here. However, seems this is an external and seemingly abandoned library this is just a minor comment.
Great work with the library! Is it still in use/active development?
I found a couple bugs in today's testing, I'll list them below rather than opening multiple issues:
python3 ./bmcli.py -a 0.001 0.005 25, constantly reports lag errors as such:[+] bitmex is lagging 86399 second(s)[+] Websocket is lagging 86399 seconds.This is exactly 24h so I'm assuming that the
ticker['timestamp']is reporting set to 1 day in the future? I didn't do extensive testing yet, just commented everything belowif self.lag >= 30:in bitmex_ws.py.2.1) I'm running into some issues with the autostop function (great idea BTW). The trailing stop part seems to work fine, but the stop loss does not. More specifically, after running
python3 ./bmcli.py -a 0.001 0.001 20and the stop loss threshold being reached, this is the output:[+] [ Params: 0.001|0.001 | 25.0] | [ High: 36924|Diff: 26.91399999999703 ][+] [ Unrealized PNL: -5e-08 | Realized PNL: -3.7e-07 | Balance: xxxxxxxx][+] [ 2021-01-16 15:29:08, Position: 1 | Entry Price: 36914.0 ][+] quote {'symbol': 'XBTUSD', 'id': 8796313950, 'side': 'Sell', 'size': 730214, 'price': 36860.5}[!] Error: 'bid'The script exits immediately after that and does not execute any sales.
2.2) The second, minor issue I observed with the autostop function is that the script doesn't terminate when autostop function successfully closes a position using the trailing stop and I need to use Ctrl+C combination to escape manually.