v4-periphery icon indicating copy to clipboard operation
v4-periphery copied to clipboard

[Bug]: Fix BaseHook with latest v4-core update

Open tomwade opened this issue 9 months ago • 3 comments

Describe the bug

After this PR the BaseHook.sol code no longer matches the IHooks.sol interface.

Expected Behavior

The params and return data should be updated in BaseHook.sol

To Reproduce

No response

Additional context

No response

tomwade avatar May 09 '24 23:05 tomwade

Sorry, I wasn't able to create this as a PR, but the changes to make this fix are minimal:

  • beforeAddLiquidity adds BalanceDelta param and BalanceDelta return
  • afterAddLiquidity adds BalanceDelta return
  • beforeSwap adds int128 return
  • afterSwap adds int128 return

I have confirmed that this works on a local branch

tomwade avatar May 09 '24 23:05 tomwade

thank you! yes we periodically update the v4-core commit that is used in periphery! hopefully we can get it updated soon but will take a bit of work with the 2 bigger changes that went in today!

hensha256 avatar May 10 '24 03:05 hensha256