docs icon indicating copy to clipboard operation
docs copied to clipboard

docs: v4 - incorrect burn position flow

Open platykurtic-icu opened this issue 11 months ago • 0 comments

In V4 Burn Position flow, there seems to be 2 errors:

  1. There should be two actions: Actions.BURN_POSITION (0x03) and Actions.TAKE_PAIR (0x11), not just Actions.BURN_POSITION to actually resolve the deltas; otherwise it reverts here: https://github.com/Uniswap/v4-core/blob/d9f8bfd39070b6114f2cf6c49df570fd6f998edb/src/PoolManager.sol#L111
  2. The actions should be abi encoded as follows:
bytes memory actions = abi.encodePacked(uint8(Actions.BURN_POSITION), uint8(Actions.TAKE_PAIR));

and not

bytes memory actions = abi.encodePacked(Actions.BURN_POSITION, Actions.TAKE_PAIR);

so, wrapping the actions into uint8()

platykurtic-icu avatar Apr 28 '25 19:04 platykurtic-icu