Over the last week, there have been many innovations in the area of decentralized finance. There was a peak in the WBTC market cap, with a single 1000 bitcoin transaction brought to Ethereum (doubling the WBTC market cap), the launch of Argent V1 which will help even less experienced users to use DeFi easily, the new version of Idle (3.0) and also the V2 version of Uniswap. Today we will talk about the last novelty, which introduces new features and a better Oracle system, confirming itself once again as one of the best DeFi platforms around. The only problem that remains at the moment, but that also affects the other DeFi protocols, is obviously the lack of liquidity. (A greater mass adoption is needed to fix this issue).
The official launch of Uniswap V2 arrived only two days ago through an announcement on the blog where all the news contained in it have been listed step by step. Developers can start building on Uniswap V2 right away by using this documentation and these examples to understand more about how the project works. Among the most important new features of Uniswap V2, there are the new ERC 20 / ERC 20 pairs, Price Oracles, Flash Swaps and much more. The old version of Uniswap, V1, will continue to exist for the time being but the team has taken care to create a very simple interface to quickly migrate to the latest available update.
ERC 20 / ERC 20 Token Swaps
This is perhaps the most important novelty of Uniswap V2 because now it is possible to trade tokens directly between them, also using swaps between stablecoins, which are particularly appreciated as before it was necessary to exchange a stablecoin with Ethereum in order to make another swap and obtain the desired stablecoin. In this case, by making one swap instead of two, one saves both additional fees and time.
Uniswap V2 also allows withdrawing all ERC 20 tokens without paying upfront fees, to use these tokens for whatever operation. Obviously afterwards it will be necessary to settle the debts and pay for the withdrawal or part of it and return all the ERC 20 tokens withdrawn.
Uniswap V2 introduces a great new feature in the Price oracle which will help the whole ecosystem to solve the problem related to recent flash loans attacks. This was announced by Vitalik Buterin already on February 18th and at last, everything seems to work as promised on the mainnet of Uniswap V2. In other words, update after update all DeFi protocols are starting to fix their own problems to make DeFi a safer place for everyone.
To learn more about the news of Uniswap V2 we recommend following the official Twitter account of the exchange (always very active). You can also consult our old articles to learn more about Uniswap and why it is one of the most important players in the DeFi industry. For the more technical users, here are the technical features of Uniswap V2, exactly as they are reported on their blog and on their official website.
Smart contracts are written in Solidity instead of Vyper; Use CREATE2 to make the pool address deterministic based on the ERC20 token pair; Uniswap V2 properly handles “missing return” ERC20 tokens that do not work on Uniswap V1, such as USDT and OMG; Built in metaTransaction “approve” function for liquidity tokens; Increase re-entrancy protection using mutex (adds support for ERC777 and other non-standard ERC20 tokens); Fix bug from Uniswap V1 that uses all remaining gas on failing transactions; More descriptive error messages. The above bug caused failing transactions to only return the error “Bad Jump Destination”