incorrect profit on frontend 2 #663
Labels
bug
Something isn't working
priority: P1
An important issue that must be fixed before the next release, but does nto require immediate focus.
When a position 'loses' tokens, possibly due to the repair command being broken, the profit reported on the frontend strategy page is wrong.
E.g. see this strategy and these positions. In both those two positions, the opening trade has a much higher quantity than the closing trade. So different methods of working out profit are giving different results.
2 possible fixes (ideally both applied):
Or alternatively, have safety check that
get_realised_profit_percent() == get_total_profit_percent()
for a closed positionSee related Discord thread
The text was updated successfully, but these errors were encountered: