- Fixed a bug in how the NFT policy IDs were being checked when restoring a PoolState from JSON.
- Small change to fetching pool data, removing hard coded pool addresses and how pool addresses are fetched by finding addresses that contain the Minswap DEX NFT.
- Small change to how swap exact in/out are calculated, where fees are now a PoolState property.
- Modified
PoolState
initialization so thatPoolDatum
is not automatically queried from blockfrost. This was causing a large number of calls to be generated to Blockfrost when usingpools.get_pools()
(one for each of the 3,000+ pools). Now, thelp_total
androot_k_last
are only retrieved from Blockfrost when requested.
Improvements:
- Added wallet support, including easy methods to create a collateral, send funds, and consolidate UTxOs.
- Swap transactions.
- Cancel transactions.
- Deposit liquidity (including zap in), but should be updated in the future. The Minswap team has not responded to requests for details on how to better estimate expected LP based on amount of token deposited. minswap/sdk#7 (comment)
Changes:
- There was an inconsistency in how time values were being cached. See the
examples/rename_time.py
for a way to translate previously cached data to the new standard. - Changed the way some of the underlying classes were managing amounts to use the
Assets
class. This makes combining assets from different UTxOs easier.
There are now multiple Minswap pool addresses. This patch updates the code to read all of them when using minswap.get_pools
and subsequent functions that require pool addresses.
- Added a blockfrost rate limiter. Every call to blockfrost adds to a time delayed counter, and prevents running into rate limits. This helps to prevent abuse of the blockfrost API.
- Added significant transaction and asset functionality. It is now possible to pull in asset historys.
- There was an inconsistency in how time values were being cached. See the
examples/rename_time.py
for a way to translate previously cached data to the new standard.