Merge pull request #2661 from freqtrade/wallet_dry

Introduce Dry-Run Wallet
This commit is contained in:
hroff-1902
2019-12-16 14:00:11 +03:00
committed by GitHub
15 changed files with 111 additions and 31 deletions

View File

@@ -348,6 +348,7 @@ class RPC:
'total': total,
'symbol': symbol,
'value': value,
'note': 'Simulated balances' if self._freqtrade.config.get('dry_run', False) else ''
}
def _rpc_start(self) -> Dict[str, str]:

View File

@@ -331,7 +331,15 @@ class Telegram(RPC):
try:
result = self._rpc_balance(self._config['stake_currency'],
self._config.get('fiat_display_currency', ''))
output = ''
if self._config['dry_run']:
output += (
f"*Warning:*Simulated balances in Dry Mode.\n"
"This mode is still experimental!\n"
"Starting capital: "
f"`{self._config['dry_run_wallet']}` {self._config['stake_currency']}.\n"
)
for currency in result['currencies']:
if currency['est_stake'] > 0.0001:
curr_output = "*{currency}:*\n" \