Add AggHook hook on ethereum#671
Open
hooklist-generator[bot] wants to merge 1 commit into
Open
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
There was a problem hiding this comment.
Review: hooks/ethereum/0x35fa675461ce9d9d7fda4b1a8b1cf767b616e888.json
Flags
Address suffix 0xe888 = binary 1110 1000 1000 1000. All 14 bits match the declared flags exactly:
| Flag | Bit | Expected | Declared |
|---|---|---|---|
| beforeInitialize | 13 | 1 | true ✓ |
| afterInitialize | 12 | 0 | false ✓ |
| beforeAddLiquidity | 11 | 1 | true ✓ |
| afterAddLiquidity | 10 | 0 | false ✓ |
| beforeRemoveLiquidity | 9 | 0 | false ✓ |
| afterRemoveLiquidity | 8 | 0 | false ✓ |
| beforeSwap | 7 | 1 | true ✓ |
| afterSwap | 6 | 0 | false ✓ |
| beforeDonate | 5 | 0 | false ✓ |
| afterDonate | 4 | 0 | false ✓ |
| beforeSwapReturnsDelta | 3 | 1 | true ✓ |
| afterSwapReturnsDelta | 2 | 0 | false ✓ |
| afterAddLiquidityReturnsDelta | 1 | 0 | false ✓ |
| afterRemoveLiquidityReturnsDelta | 0 | 0 | false ✓ |
Properties
- dynamicFee: false ✓ —
beforeSwapreturns a fee override of 0 (mstore(0x40, 0)). Protocol fees are collected via the PoolManagerdonate()call (_fee()function), not via LP fee override. NoupdateDynamicLPFee()call present. - upgradeable: false ✓ — No proxy pattern, no
delegatecall, noSELFDESTRUCT. Pool addresses are embedded as immutable bytecode constants. - requiresCustomSwapData: false ✓ —
beforeSwapignores thehookDatabytes calldata parameter entirely; routing uses on-chain pool state and bytecode-embedded pool keys only. - vanillaSwap: false ✓ — Correct.
beforeSwapReturnsDeltais true andbeforeSwapexecutes cross-pool swaps internally (both V3 pools viauniswapV3SwapCallback/pancakeV3SwapCallbackand V4 pools via the PoolManager swap selector), fundamentally changing how the swap executes. - swapAccess: "none" ✓ —
beforeSwaponly calls_onlyPoolManager()(standard protocol requirement that caller is PoolManager). UnlikebeforeAddLiquidityandbeforeInitialize,beforeSwapdoes not call_onlyAdmin(). No restriction on who can initiate swaps.
Metadata
- verifiedSource: true ✓ — Confirmed by
source_meta.json. - chainId: 1 ✓ — Confirmed by
Mainnet.sol: PM =0x000000000004444c5dc75cB358380D2e3dE08A90(Uniswap v4 PoolManager on mainnet), GAS_TOKEN =0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2(WETH). - name: "AggHook" ✓ — Matches
ContractNamefrom verified source (contract AggHook is Router). - description ✓ — Accurately describes the aggregation/routing behavior: the hook sorts pools by effective price (
_rfq041/_rfq140), routes through up to 10 pools (3 V4 + 7 V3), and handles both V3 callbacks (uniswapV3SwapCallback,pancakeV3SwapCallback) and V4 nested swaps. No audit claims, safety guarantees, or unsubstantiated marketing language.
Conclusion
All flags, properties, and metadata are correct and substantiated by the on-chain source code.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
A Uniswap v4 hook that automatically routes swaps across multiple registered liquidity uniswapV3like pools from Uniswap, Pancakeswap, Sushiswap, Aerodrome, etc. By discovering and executing the most efficient path at transaction time, it allows traders to access deeper aggregated liquidity, improve price execution, and reduce the effects of liquidity fragmentation.
Flags
Properties
Warnings
None
Closes #669