21jake / Binance-volatility-trading-bot-JS

This Binance trading bot detects the most volatile cryptos to buy and later sell at predefined Take Profit / Stop Loss thresholds.
MIT License
35 stars 6 forks source link

Console output - add date/time and output all to a log file #8

Closed daddywookie closed 3 years ago

daddywookie commented 3 years ago

When there is a long period where nothing happens it can be hard to keep track of the executions. It might be helpful to add a timestamp to the output to make it clearer what is happening and when.

[2021/05/18 18:05:02] No coin has risen more than 5% in the last 5 minutes
[2021/05/18 18:05:02] MATICUSDT price has hit SL threshold
[2021/05/18 18:05:03] The asset MATICUSDT has been sold sucessfully at the profit of -5.72% and recorded in sold-assets.json
[2021/05/18 18:05:03] Wait for the bot to gather data to check price volatility...

Also, outputting the console to a .log file would help with troubleshooting. This might need to be configured with some form of log rotation.

21jake commented 3 years ago

Fair point, implemented since 21jake@2d9fb75

daddywookie commented 3 years ago

Will update and test on my next run.