Skip to content

feat: add CCTPv2 action contracts#111

Open
O1ahmad wants to merge 5 commits intomainfrom
ahmad/add_cctpv2_transfer-sweep_contracts
Open

feat: add CCTPv2 action contracts#111
O1ahmad wants to merge 5 commits intomainfrom
ahmad/add_cctpv2_transfer-sweep_contracts

Conversation

@O1ahmad
Copy link
Member

@O1ahmad O1ahmad commented Dec 10, 2025

Motivation

contributes to ENG-1492

Solution

  • see Circle's v1 -> v2 contract migration guide and v2 ABIs
  • note that usage of the depositForBurn TokenMessengerV2 function now exposes the destinationCaller property which can either limit message processing to a specific address or allow any with specification of the 0 address - v1 contracts currently hardcode this property to the 0 address. Setting of this property can be propagated from FE clients to the instruction settings and offchain executor logistics

Reviewer Checklist

  • tests have been added to validate the change
  • code has been commented, particularly in hard-to-understand areas
  • corresponding documentation updates have been made

@otim-squirrel otim-squirrel bot added the feature New feature or functionality label Dec 10, 2025
@otim-squirrel
Copy link

otim-squirrel bot commented Dec 10, 2025

Linked to Slack thread successfully

@github-actions
Copy link

github-actions bot commented Dec 10, 2025

Forge code coverage:

File % Lines % Statements % Branches % Funcs
src/OtimDelegate.sol 100.00% (43/43) 100.00% (58/58) 100.00% (12/12) 100.00% (5/5)
src/actions/CallOnceAction.sol 95.65% (22/23) 100.00% (27/27) 100.00% (6/6) 75.00% (3/4)
src/actions/DeactivateInstructionAction.sol 94.12% (16/17) 100.00% (18/18) 100.00% (2/2) 75.00% (3/4)
src/actions/DepositERC4626Action.sol 93.33% (28/30) 97.50% (39/40) 100.00% (7/7) 66.67% (2/3)
src/actions/RefuelAction.sol 91.30% (21/23) 96.30% (26/27) 83.33% (5/6) 66.67% (2/3)
src/actions/RefuelERC20Action.sol 95.45% (21/22) 100.00% (28/28) 100.00% (4/4) 66.67% (2/3)
src/actions/SweepAction.sol 90.48% (19/21) 96.30% (26/27) 80.00% (4/5) 66.67% (2/3)
src/actions/SweepCCTPAction.sol 96.55% (28/29) 100.00% (35/35) 100.00% (5/5) 75.00% (3/4)
src/actions/SweepCCTPV2Action.sol 94.44% (34/36) 97.67% (42/43) 87.50% (7/8) 75.00% (3/4)
src/actions/SweepDepositERC4626Action.sol 96.55% (28/29) 100.00% (42/42) 100.00% (6/6) 66.67% (2/3)
src/actions/SweepERC20Action.sol 94.74% (18/19) 100.00% (25/25) 100.00% (3/3) 66.67% (2/3)
src/actions/SweepUniswapV3Action.sol 98.36% (60/61) 100.00% (68/68) 100.00% (11/11) 85.71% (6/7)
src/actions/SweepWithdrawERC4626Action.sol 96.15% (25/26) 100.00% (34/34) 100.00% (5/5) 66.67% (2/3)
src/actions/TransferAction.sol 90.48% (19/21) 95.83% (23/24) 83.33% (5/6) 66.67% (2/3)
src/actions/TransferCCTPAction.sol 93.55% (29/31) 97.06% (33/34) 100.00% (6/6) 75.00% (3/4)
src/actions/TransferCCTPV2Action.sol 92.11% (35/38) 95.24% (40/42) 88.89% (8/9) 75.00% (3/4)
src/actions/TransferERC20Action.sol 88.89% (16/18) 95.83% (23/24) 100.00% (4/4) 66.67% (2/3)
src/actions/TransferERC20OnceAction.sol 94.12% (16/17) 100.00% (23/23) 100.00% (2/2) 66.67% (2/3)
src/actions/TransferOnceAction.sol 88.89% (16/18) 95.65% (22/23) 75.00% (3/4) 66.67% (2/3)
src/actions/UniswapV3ExactInputAction.sol 96.43% (54/56) 98.44% (63/64) 100.00% (10/10) 85.71% (6/7)
src/actions/WithdrawERC4626Action.sol 90.91% (20/22) 96.55% (28/29) 100.00% (5/5) 66.67% (2/3)
src/actions/fee-models/OtimFee.sol 90.91% (20/22) 100.00% (29/29) 100.00% (7/7) 33.33% (1/3)
src/actions/libraries/AssemblyUtils.sol 100.00% (9/9) 100.00% (8/8) 100.00% (1/1) 100.00% (2/2)
src/actions/libraries/UniswapV3OracleParameters.sol 100.00% (17/17) 95.45% (21/22) 0.00% (0/1) 100.00% (2/2)
src/actions/schedules/Interval.sol 75.00% (9/12) 100.00% (17/17) 100.00% (6/6) 0.00% (0/3)
src/context/Receiver.sol 100.00% (9/9) 100.00% (9/9) 100.00% (0/0) 100.00% (4/4)
src/core/ActionManager.sol 100.00% (23/23) 100.00% (20/20) 100.00% (4/4) 100.00% (7/7)
src/core/Gateway.sol 100.00% (16/16) 100.00% (12/12) 100.00% (3/3) 100.00% (5/5)
src/core/InstructionStorage.sol 100.00% (48/48) 100.00% (40/40) 100.00% (1/1) 100.00% (8/8)
src/core/references/InstructionStorageReference.sol 75.00% (15/20) 78.57% (11/14) 0.00% (0/1) 75.00% (6/8)
src/infrastructure/CrossRatePriceFeed.sol 100.00% (31/31) 100.00% (43/43) 100.00% (4/4) 100.00% (3/3)
src/infrastructure/FeeTokenRegistry.sol 100.00% (30/30) 100.00% (44/44) 100.00% (9/9) 100.00% (3/3)
src/infrastructure/InvertedPriceFeed.sol 69.23% (9/13) 70.00% (7/10) 100.00% (0/0) 66.67% (2/3)
src/infrastructure/Treasury.sol 93.33% (14/15) 92.86% (13/14) 80.00% (4/5) 100.00% (3/3)
src/libraries/Instruction.sol 100.00% (6/6) 100.00% (6/6) 100.00% (0/0) 100.00% (3/3)
Total 90.87% (956/1052) 96.03% (1113/1159) 94.22% (163/173) 73.04% (149/204)

@O1ahmad O1ahmad force-pushed the ahmad/add_cctpv2_transfer-sweep_contracts branch 5 times, most recently from ee0eecf to 3f497a0 Compare December 10, 2025 20:05
@O1ahmad O1ahmad force-pushed the ahmad/add_cctpv2_transfer-sweep_contracts branch from 3f497a0 to aaef78e Compare December 11, 2025 16:07
@O1ahmad O1ahmad requested review from Jrachman and dv3-000 December 12, 2025 17:29
@O1ahmad O1ahmad force-pushed the ahmad/add_cctpv2_transfer-sweep_contracts branch from 952766c to 709acc9 Compare January 13, 2026 17:56
@O1ahmad O1ahmad force-pushed the ahmad/add_cctpv2_transfer-sweep_contracts branch 2 times, most recently from 411b67b to 821d7cc Compare January 15, 2026 19:15
@O1ahmad O1ahmad force-pushed the ahmad/add_cctpv2_transfer-sweep_contracts branch from 821d7cc to ab65752 Compare January 15, 2026 19:15
@O1ahmad O1ahmad requested a review from dv3-000 January 23, 2026 20:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature New feature or functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants