Add Rivers LaunchHook hook on robinhood#1102
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
Review: hooks/robinhood/0xcd87186fc4f809241f3e7ff3ca557bb7cc962acc.json
Address Flags
The address ends in 0x2acc. Lowest 14 bits = 10 1010 1100 1100:
| Bit | Flag | Expected | JSON |
|---|---|---|---|
| 13 | beforeInitialize | true | true ✓ |
| 12 | afterInitialize | false | false ✓ |
| 11 | beforeAddLiquidity | true | true ✓ |
| 10 | afterAddLiquidity | false | false ✓ |
| 9 | beforeRemoveLiquidity | true | true ✓ |
| 8 | afterRemoveLiquidity | false | false ✓ |
| 7 | beforeSwap | true | true ✓ |
| 6 | afterSwap | true | true ✓ |
| 5 | beforeDonate | false | false ✓ |
| 4 | afterDonate | false | false ✓ |
| 3 | beforeSwapReturnsDelta | true | true ✓ |
| 2 | afterSwapReturnsDelta | true | true ✓ |
| 1 | afterAddLiquidityReturnsDelta | false | false ✓ |
| 0 | afterRemoveLiquidityReturnsDelta | false | false ✓ |
All flags match the address bitmask. The _requiredPermissions() function in the source confirms the same set.
Properties
-
dynamicFee: true ✓ —
beforeSwapreturnslpFee | LPFeeLibrary.OVERRIDE_FEE_FLAGon every call, overriding the LP fee dynamically (switching betweenPRE_GRADUATION_LP_FEEandPOST_GRADUATION_LP_FEEbased on phase). -
upgradeable: false ✓ — No proxy pattern, delegatecall, or selfdestruct in the source. Immutable
poolManagerandfeeController. -
requiresCustomSwapData: false ✓ —
hookDatais optional. When absent (hookData.length != 32),_isProtocolFeeExemptand_isGraduationCrossingreturn false and swaps proceed normally with fee deduction. The hook does not revert on empty hookData. -
vanillaSwap: false ✓ —
dynamicFeeis true,beforeSwapReturnsDeltaandafterSwapReturnsDeltaare true, and the hook executes token transfers (poolManager.take) inside beforeSwap/afterSwap. Swap execution is materially altered. -
swapAccess: governance ✓ — In pre-graduation phases,
beforeSwapgates onconfig.phase(set by the controller/admin):if (!feeActive && sender != config.controller) revert UnauthorizedAction(sender). This is a boolean-flag style state set by an owner/admin, fitting the "governance" classification.
Metadata
- verifiedSource: true ✓ — Confirmed by
source_meta.json. - chainId: 4663 ✓ — Matches
chains.jsonentry for "robinhood". - name: "Rivers LaunchHook" ✓ — Contract is named
LaunchHook; NatSpec says "Singleton v4 hook serving registered Rivers launch pools." "Rivers LaunchHook" is a project-qualified label substantiated by the source. No promotional language. - description ✓ — Accurately describes the lifecycle (CREATED → SEEDED → BOOTSTRAP_ACTIVE → GRADUATION_PENDING → GRADUATED_LP_ACTIVE → PARTICIPANT_LADDER_SETTLED), pre-graduation access restriction to controller, and post-graduation fee mechanics via BeforeSwapDelta/AfterSwapDelta with dynamic LP fee override. No audit claims or marketing language.
All fields verified against the on-chain source. No issues found.
Summary
Singleton Uniswap v4 hook for Rivers protocol launch pools, managing a pre/post-graduation lifecycle. During pre-launch phases, liquidity and swaps are restricted to the pool controller. After graduation, public swaps are enabled with protocol and creator fees taken as BeforeSwapDelta/AfterSwapDelta values and a dynamic LP fee override returned from beforeSwap.
Flags
Properties
Warnings
Closes #1096