That was liquidation. (Yes, kind of margin call) Why it happened? Because at the time of liquidation your borrowing position reached your borrow limit due to very fast rise in price of Ether. You should not allow your borrow side to reach 100% of your limit as at that very moment you will be marked for liquidation and WILL be liquidated, even if it in reality will be just very short spike and price will go back shortly after. ETH and BTC are in bull market recently and able to have very big price movements in extremelly short timeframes. For that reason if you borrow ETH against stablecoin, 80% is very dangerous position, it’s nowhere near safe. It’s quite risky to have it above 50% actually. Luckily for you, Compound allows only 50% of a position to be liquidated and liquidation fee is less than 10% also, so you end up in better position than those leveraged traders on bitmex and similar services, but you will still lose some money on liquidation, so in your best interest is to not let it happen.
- As for gas fee, it’s not that much depends on liquidator. High volatility of ETH price commonly happens together with spike of transaction fees. You have to pay a lot of fee to make transaction pass through during that period. There are also some risks for liquidators, technically transaction might be frontrunned by somebody else, and liquidator ends up paying gas fee and having transaction not executed, so they commonly overshoot by big margin in terms of gas fee, to make sure they execute fast and first. In your case he could probably get it done for half the price, but liquidation it’s not a situation when you want to be cheap and someone do it before you.
Generally nothing went wrong, you kind of put yourself in risky position by not letting enough room for ETH price to go up. When borrowing high volatility asset against a stable asset, try to leave very big margin, certanly not going to 80% of borrow limit, unless you doing it for a very short time. For any type of long term borrowing you should keep utilisation much lower. Hope it explains.