Fix failed ETH cashouts
Some months back we've received a report from Xavi Zambrana regarding failed outgoing ETH txs:
Coincidentally, that day, September 27th 2020, there was a peak of 0.30265 ether on the fee price:
As a first step to debug this issue, we decided with the tech team to switch from the old version of parity we were running as our node, to the latest stable version of geth
, which after a careful process we've managed to complete recently. See #94
We've been experimenting the fee cap (geth --rpc.txfeecap ) to limit the fee our node would pay to the network for tx's and noticed it won't help as in case the network requires a higher fee exceeding the cap, the tx would fail and just not happen.
This was an intent to overcome the situations when fee costs peaks (like what happened when @xavislow reported the issue), but it seems we would be introducing a new issue trying and not actually succeeding to solve another one, which is avoid failing txs from our wallet.
It seems we should live with it, as fees prices fluctuate all the time.
A potential solution is to always have some spare eth on the node's payout address (the default geth txfeecap is 1 ETH actually)
Another part of the fees story to understand for us is how BotC handles the fees, and review the whole eth cashflow, as there is a middle step involved when a member wants to cashout, where we have to manually move funds from their account to the main (payout) address which is of course undesirable. But we'll create a separate issue for that.
An idea could be to create a cronjob to collect the funds from the different addresses and store them on the payout address, capped to a max amount to keep funds safer, as they cannot leave the node if not on the main address.
Let's get some feedback and take a decision.