Skip to content

aerodrome-finance/slipstream

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1,152 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Slipstream

This repository contains the smart contracts for the Slipstream Concentrated Liquidity contracts. It contains the core concentrated liquidity contracts, adapted from UniswapV3's core contracts. It contains the higher level periphery contracts, adapted from UniswapV3's periphery contracts. It also contains gauges designed to operate within the Velodrome ecosystem.

See SPECIFICATION.md and CHANGELOG.md for more information.

Installation

This repository is a hybrid hardhat and foundry repository.

Install hardhat dependencies with yarn install. Install foundry dependencies with forge install.

Run hardhat tests with yarn test. Run forge tests with forge test.

Testing

Invariants

To run the invariant tests, echidna must be installed. The following instructions require additional installations (e.g. of solc-select).

echidna test/invariants/E2E_mint_burn.sol --config test/invariants/E2E_mint_burn.config.yaml --contract E2E_mint_burn
echidna test/invariants/E2E_swap.sol --config test/invariants/E2E_swap.config.yaml --contract E2E_swap

Licensing

As this repository depends on the UniswapV3 v3-core and v3-periphery repository, the contracts in the contracts/core and contracts/periphery folders are licensed under GPL-2.0-or-later or alternative licenses (as indicated in their SPDX headers).

Files in the contracts/gauge folder are licensed under the Business Source License 1.1 (BUSL-1.1).

Bug Bounty

Velodrome has a live bug bounty hosted on (Immunefi).

Deployments

Initial Deployment

Initial deployment of Slipstream contracts on Base.

Name Address
GaugeFactory 0xD30677bd8dd15132F251Cb54CbDA552d2A05Fb08
GaugeImplementation 0xF5601F95708256A118EF5971820327F362442D2d
MixedQuoter 0x0A5aA5D3a4d28014f967Bf0f29EAA3FF9807D5c6
NonfungiblePositionManager 0x827922686190790b37229fd06084350E74485b72
NonfungibleTokenPositionDescriptor 0x01b0CaCB9A8004e08D075c919B5dF3b59FD53c55
PoolFactory 0x5e7BB104d84c7CB9B682AaC2F3d509f5F406809A
PoolImplementation 0xeC8E5342B19977B4eF8892e02D8DAEcfa1315831
QuoterV2 0x254cF9E1E6e233aa1AC962CB9B05b2cfeAaE15b0
CustomSwapFeeModule 0xF4171B0953b52Fa55462E4d76ecA1845Db69af00
CustomUnstakedFeeModule 0x0AD08370c76Ff426F534bb2AFFD9b5555338ee68
SwapRouter 0xBE6D8f0d05cC4be24d5167a3eF062215bE6D18a5
SugarHelper 0x0AD09A66af0154a84e86F761313d02d0abB6edd5
DynamicSwapFeeModule 0x090b2A6bb475c00e2256e2095A60887cD710803b

Gauge Caps Deployment

Deployment with gauge emission cap enforcement and redistributor functionality to manage and reallocate excess emissions.

Key Changes:

  • Gauge Caps:
    • CLGauge enforces emission caps to limit rewards per gauge.
    • The emission cap is set as a percentage of total weekly emissions.
    • When a gauge exceeds its cap, excess emissions are automatically transferred to the Redistributor.
  • Redistributor:
    • Manages redistribution of excess emissions when gauges exceed their caps.
    • Collects excess emissions from capped gauges and redistributes them to other eligible gauges proportionally to their voting weight.
Name Address
GaugeFactory 0xB630227a79707D517320b6c0f885806389dFcbB3
GaugeImplementation 0xC0d2086B6f70C0C40423626167096c6196cFA0c8
MixedQuoter 0x49540630A4d2CE67d54450D007D634F4c45B4f4f
NonfungiblePositionManager 0xa990C6a764b73BF43cee5Bb40339c3322FB9D55F
NonfungibleTokenPositionDescriptor 0xf632031B94D72deE0D99DeF846c9b6211041337f
PoolFactory 0xaDe65c38CD4849aDBA595a4323a8C7DdfE89716a
PoolImplementation 0x942e97a4c6FdC38B4CD1c0298D37d81fDD8E5A16
Quoter 0x3d4C22254F86f64B7eC90ab8F7aeC1FBFD271c6C
SwapFeeModule 0x5264Eeeab16037A7A7AF15Ff69A470af6e2a2223
SwapRouter 0xcbBb8035cAc7D4B3Ca7aBb74cF7BdF900215Ce0D
UnstakedFeeModule 0xCCC21f4750E8B3E9C095BCB5d2fF59247A2CCD35
DynamicSwapFeeModule 0xF4Ecd78EBEB6d36CF7f80B5B6B41453515fe2785
Redistributor 0x11a53f31Bf406de59fCf9613E1922bd3E283A4B4

Gauges V3 Deployment

This is the current latest deployment of the gauges. Existing gauges are still in use, but all new gauges will be deployed from here.

Key Changes:

  • Minimum Stake Time: Per-pool configurable minimum stake duration.
  • Early Unstake Penalty: Penalty rate applied to both getReward and withdraw if called before the minimum stake time has elapsed.
  • Dynamic Swap Fee Module: Replaces CustomSwapFeeModule with dynamic fee scaling based on tick crossings.
  • MixedRouteQuoterV3: New quoter supporting 3 CL factories via bitmask encoding.
  • Redistributor: Updated to support dual CL gauge factories.
Name Address
DynamicSwapFeeModule 0x87D8f999BBa9343E8099552426775B51C338E8CB
GaugeFactory 0x385293CaE378C813F16f0C1334d774AdDDf56AbB
GaugeImplementation 0x434BCcaB043311a20b16021C137EA81702790f7B
MixedQuoter 0x9951FF0b830E46ef0e7Ce34d9117e3214B1F0b5a
MixedQuoterV2 0xb4A9E5Fc0727BEF09D819fcfc5ece8CA9bCf09EB
MixedQuoterV3 0xCd2A7D98e82D6107eac1828ce8DeAA6acB65b555
NonfungiblePositionManager 0xe1f8cd9AC4e4A65F54f38a5CdAfCA44f6dD68b53
NonfungibleTokenPositionDescriptor 0xc85C126442bb5B654792A70135805a9778C8e3fE
PoolFactory 0xf8f2eB4940CFE7d13603DDDD87f123820Fc061Ef
PoolImplementation 0xc770898522D2A9c8Da7A10D63989b6b58305B665
Quoter 0x514c8B5f54112481E28028F1166Bd78501089259
Redistributor 0xEe5b3C7b333e2870B746b3B2b168EF0958e55e15
SwapRouter 0x698Cb2b6dd822994581fEa6eA4Fc755d1363A92F
UnstakedFeeModule 0xc2cc3256434AfbC36Bb5e815e1Bb2151310a1a0b

About

Aerodrome Finance Concentrated Liquidity Contracts

Resources

License

Stars

27 stars

Watchers

1 watching

Forks

Packages

 
 
 

Contributors

Languages

  • Solidity 72.1%
  • TypeScript 27.9%