Consistently erroring out at line 274 in Binance Detect Moonings.py . with Key Error. Occurs when market conditions are good in attempt to initiate buys:
Traceback (most recent call last):
File ".\Binance Detect Moonings.py", line 600, in
orders, last_price, volume = buy()
File ".\Binance Detect Moonings.py", line 300, in buy
volume, last_price = convert_volume()
File ".\Binance Detect Moonings.py", line 281, in convert_volume
volume[coin] = float(QUANTITY / float(last_price[coin]['price']))
KeyError: 'ADAUSDT'
I printed out volatile_coins and last_price . Shoudn't volatile_coins be a subset of last_price? Majority of coins here do not exist in last_price.
e.g.
[2021-05-31 11:57:44] Working...Session profit:0.00% Est:$0.00
[2021-05-31 11:57:44] Signalsample:BCHUSDT First 14 Second 15
[2021-05-31 11:57:44] Signalsample: Signal detected on BCHUSDT
[2021-05-31 11:57:44] Signalsample:UNIUSDT First 14 Second 15
[2021-05-31 11:57:44] Signalsample: Signal detected on UNIUSDT
[2021-05-31 11:57:44] External signal received on BTCUSDT, calculating volume in USDT
[2021-05-31 11:57:44] External signal received on ETHUSDT, calculating volume in USDT
[2021-05-31 11:57:44] External signal received on BNBUSDT, calculating volume in USDT
[2021-05-31 11:57:44] External signal received on ADAUSDT, calculating volume in USDT
[2021-05-31 11:57:44] External signal received on DOTUSDT, calculating volume in USDT
[2021-05-31 11:57:44] External signal received on BCHUSDT, calculating volume in USDT
[2021-05-31 11:57:44] <class 'dict'>
[2021-05-31 11:57:44] vc 0 : BTCUSDT
[2021-05-31 11:57:44] vc 1 : ETHUSDT
[2021-05-31 11:57:44] vc 2 : BNBUSDT
[2021-05-31 11:57:44] vc 3 : ADAUSDT
[2021-05-31 11:57:44] vc 4 : DOTUSDT
[2021-05-31 11:57:44] vc 5 : BCHUSDT
[2021-05-31 11:57:45] Signalsample:LTCUSDT First 17 Second 17
[2021-05-31 11:57:45] Signalsample: Signal detected on LTCUSDT
[2021-05-31 11:57:45] <class 'dict'>
[2021-05-31 11:57:45] lp 0 : BNBUSDT
[2021-05-31 11:57:45] lp 1 : BTCUSDT
[2021-05-31 11:57:45] lp 2 : ETHUSDT
[2021-05-31 11:57:45] lp 3 : LTCUSDT
[2021-05-31 11:57:45] lp 4 : XRPUSDT
[2021-05-31 11:57:45] Signalsample:LINKUSDT First 11 Second 15
[2021-05-31 11:57:45] Signalsample:SOLUSDT First 12 Second 14
[2021-05-31 11:57:45] Signalsample: Signal detected on SOLUSDT
[2021-05-31 11:57:46] Signalsample:ETCUSDT First 14 Second 15
[2021-05-31 11:57:46] Signalsample: Signal detected on ETCUSDT
[2021-05-31 11:57:46] Signalsample:FILUSDT First 17 Second 16
[2021-05-31 11:57:46] Signalsample: Signal detected on FILUSDT
[2021-05-31 11:57:47] Signalsample:EOSUSDT First 13 Second 15
[2021-05-31 11:57:47] Signalsample: Signal detected on EOSUSDT
[2021-05-31 11:57:47] <class 'dict'>
[2021-05-31 11:57:47] lp 0 : BNBUSDT
[2021-05-31 11:57:47] lp 1 : BTCUSDT
[2021-05-31 11:57:47] lp 2 : ETHUSDT
[2021-05-31 11:57:47] lp 3 : LTCUSDT
[2021-05-31 11:57:47] lp 4 : XRPUSDT
[2021-05-31 11:57:47] Signalsample:XMRUSDT First 16 Second 17
[2021-05-31 11:57:47] Signalsample: Signal detected on XMRUSDT
[2021-05-31 11:57:47] Signalsample: Max signal by LTCUSDT at 17 on shortest timeframe
[2021-05-31 11:57:47] Signalsample: 14 coins above 12 treshold on both timeframes. Waiting 1 minutes for next analysis
[2021-05-31 11:57:47] <class 'dict'>
[2021-05-31 11:57:47] lp 0 : BNBUSDT
[2021-05-31 11:57:47] lp 1 : BTCUSDT
[2021-05-31 11:57:47] lp 2 : ETHUSDT
[2021-05-31 11:57:47] lp 3 : LTCUSDT
[2021-05-31 11:57:47] lp 4 : XRPUSDT
[2021-05-31 11:57:48] <class 'dict'>
[2021-05-31 11:57:48] lp 0 : BNBUSDT
[2021-05-31 11:57:48] lp 1 : BTCUSDT
[2021-05-31 11:57:48] lp 2 : ETHUSDT
[2021-05-31 11:57:48] lp 3 : LTCUSDT
[2021-05-31 11:57:48] lp 4 : XRPUSDT
Traceback (most recent call last):
File ".\Binance Detect Moonings.py", line 600, in
orders, last_price, volume = buy()
File ".\Binance Detect Moonings.py", line 300, in buy
volume, last_price = convert_volume()
File ".\Binance Detect Moonings.py", line 281, in convert_volume
volume[coin] = float(QUANTITY / float(last_price[coin]['price']))
KeyError: 'ADAUSDT'
Here is my config:
{
"script_options": {
"TEST_MODE": true,
"LOG_TRADES": true,
"LOG_FILE": "trades.txt",
"AMERICAN_USER": true
},
"trading_options": {
"PAIR_WITH": "USDT",
"QUANTITY": 15,
"FIATS": [
"EURUSDT",
"GBPUSDT",
"JPYUSDT",
"USDUSDT",
"DOWN",
"UP"
],
"MAX_COINS": 7,
"TIME_DIFFERENCE": 1,
"RECHECK_INTERVAL": 60,
"CHANGE_IN_PRICE": 10,
"STOP_LOSS": 0.18,
"TAKE_PROFIT": 0.6,
"CUSTOM_LIST": true,
"TICKERS_LIST": "tickers.txt",
"USE_TRAILING_STOP_LOSS": false,
"TRAILING_STOP_LOSS": 0.4,
"TRAILING_TAKE_PROFIT": 0.1,
"TRADING_FEE": 0.075,
"SIGNALLING_MODULES": [
"pausebotmod",
"signalsamplemod"
]
}
}