Product updates and announcements
Breaking Change: Generated Struct Names Now Include Contract Names
With CLI version v0.0.79 and upwards, there will be a breaking change that impacts users who import and use generated structs from the ABI.
Why this change was needed:
The same struct name can be used across different contracts (example: GPv2Trade.Data
and GPv2Interaction.Data
within the same ABI) with different definitions. Using just the struct name for generated structs prevented proper triggering on protocols like CoW Swap.
What changed:
We now include the contract name as part of the struct name in the generated Solidity file associated with the ABI. Instead of using $AbiName$StructName
for the names, we now use $AbiName$ContractName$StructName
.
Impact: If you have imported a generated struct, you’ll need to update the name to include the contract name the next time you run codegen. This doesn’t impact the default inputs/outputs/context structs, so most users won’t encounter this issue.
Who is affected: You’ll only run into this issue if you:
New Feature: Multiple Listener Contracts Support
The Sim CLI now supports defining multiple listener contracts within a single IDX application, enabling better code organization and structure.
What’s new:
Main.sol
Main.sol
file still needs to contain the Triggers
contract, but individual listeners can be defined anywheresim listeners evaluate
command to target specific listeners for focused testingBenefits:
Migration:
Main.sol
must still exist and contain your Triggers
contractThis feature is particularly valuable for complex applications like DEX trade indexers that may have 15+ listeners and benefit from better file organization.
New Feature: Pre-Execution Triggers
The Sim CLI now supports pre-execution triggers, allowing you to execute code before a function runs instead of the default behavior of executing after.
What’s new:
Pre-
abstract contracts (e.g., preCreatePoolFunction
)PreFunctionContext
with access to function inputs only (outputs haven’t been generated yet)Use cases:
For detailed implementation examples and usage patterns, see the Function Triggers documentation.