mirror of
https://github.com/freqtrade/freqtrade.git
synced 2024-11-10 10:21:59 +00:00
add whitelist to execute_sell and append sold pair to it
This commit is contained in:
parent
f84c58c3eb
commit
e9e76da054
2
main.py
2
main.py
|
@ -94,8 +94,10 @@ def execute_sell(trade: Trade, current_rate: float) -> None:
|
|||
# Get available balance
|
||||
currency = trade.pair.split('_')[1]
|
||||
balance = exchange.get_balance(currency)
|
||||
whitelist = _CONF[trade.exchange.name.lower()]['pair_whitelist']
|
||||
|
||||
profit = trade.exec_sell_order(current_rate, balance)
|
||||
whitelist.append(trade.pair)
|
||||
message = '*{}:* Selling [{}]({}) at rate `{:f} (profit: {}%)`'.format(
|
||||
trade.exchange.name,
|
||||
trade.pair.replace('_', '/'),
|
||||
|
|
Loading…
Reference in New Issue
Block a user