Add RiversLaunchHook hook on robinhood#1092
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Review: hooks/robinhood/0x12783b423b9cf1a136bd7e0f8baca5944f5baacc.json
Contract: LaunchHook (source verified on Robinhood chain)
Address Flag Verification
Address ends in 0xaacc = 1010 1010 1100 1100 binary. Lowest 14 bits:
| Bit | Flag | Address | JSON |
|---|---|---|---|
| 13 | beforeInitialize | 1 | true ✓ |
| 12 | afterInitialize | 0 | false ✓ |
| 11 | beforeAddLiquidity | 1 | true ✓ |
| 10 | afterAddLiquidity | 0 | false ✓ |
| 9 | beforeRemoveLiquidity | 1 | true ✓ |
| 8 | afterRemoveLiquidity | 0 | false ✓ |
| 7 | beforeSwap | 1 | true ✓ |
| 6 | afterSwap | 1 | true ✓ |
| 5 | beforeDonate | 0 | false ✓ |
| 4 | afterDonate | 0 | false ✓ |
| 3 | beforeSwapReturnsDelta | 1 | true ✓ |
| 2 | afterSwapReturnsDelta | 1 | true ✓ |
| 1 | afterAddLiquidityReturnsDelta | 0 | false ✓ |
| 0 | afterRemoveLiquidityReturnsDelta | 0 | false ✓ |
All flags match.
Properties Verification
-
dynamicFee: true ✓ —
beforeSwapreturnslpFee | LPFeeLibrary.OVERRIDE_FEE_FLAG, switching betweenPRE_GRADUATION_LP_FEEandPOST_GRADUATION_LP_FEEbased on the pool phase. -
upgradeable: false ✓ — No proxy pattern, no
delegatecall, no mutable implementation storage, noSELFDESTRUCT. UsesimmutableforpoolManagerandfeeController. -
requiresCustomSwapData: false ✓ — Public swaps (when fee-active) work with empty
hookData; the hook just charges protocol + creator fees.hookDatais only checked to grant fee exemptions or identify special internal swap types (e.g.,GRADUATION_CROSSING_MARKER). A normal swap with emptyhookDataexecutes and charges fees without reverting. -
vanillaSwap: false ✓ — Correctly false:
dynamicFeeis true,beforeSwapReturnsDeltaandafterSwapReturnsDeltaare both true, and the hook actively extracts trade fees viapoolManager.take(). -
swapAccess: "governance" ✓ —
beforeSwapgates on_feeActive(config.phase), which is a boolean flag derived from the pool's phase state (set by the controller viaactivateBootstrap,finalizeGraduation, etc.). Before graduation, only the controller can swap. This is a governance-flag pattern.
Metadata Verification
- chainId: 4663 ✓ — Matches
chains.jsonentry for"robinhood". - verifiedSource: true ✓ — Confirmed by
source_meta.json("verified": true). - name: "RiversLaunchHook" ✓ —
LaunchHookis the contract name; "Rivers" is substantiated by the NatSpec ("Singleton v4 hook serving registered Rivers launch pools") and by constants likeRIVERS_AUTOMATIC_SETTLEMENTandRIVERS_GRADUATION_CROSSING. No promotional language. - description ✓ — All claims are substantiated: singleton pattern (NatSpec), phased launches (Phase enum with 6 states), controller-only swaps before graduation (
!feeActive && sender != config.controller → revert), dynamic LP fee override, and fee collection viabeforeSwap/afterSwapdeltas (_takeTradeFees,toBeforeSwapDelta,unspecifiedFeeDelta). No marketing or audit language.
Conclusion
All flags, properties, and metadata are accurate and consistent with the verified on-chain source code.
Summary
A singleton Uniswap v4 hook for the Rivers protocol that manages phased token launches. Restricts swaps to the controller before fee activation, dynamically overrides LP fees based on pool phase (pre/post-graduation), and collects protocol trade fees from public swaps via beforeSwap/afterSwap deltas.
Flags
Properties
Warnings
Closes #1084