Releases: foundry-rs/starknet-foundry
Releases · foundry-rs/starknet-foundry
0.20.0
Forge
Added
- variants of cheatcodes with
CheatSpan(read more here) - Providing configuration data with env variables DOCS
Fixed
- Events emitted in cairo 0 contracts are now properly collected
--build-profileno longer fails silently (compatible withcairo-profiler0.2.0)
Changed
- Default
chain_idhas been changed fromSN_GOERLItoSN_SEPOLIA - Supported RPC version is now 0.7.0
- Gas calculation is in sync with starknet 0.13.1 (with EIP 4844 blob usage enabled)
- Resources displayed (steps, builtins) now include OS costs of syscalls
Cast
Added
- Support for OpenZeppelin Cairo 1 (or higher) accounts creation, deployment and usage
- Providing configuration data with env variables DOCS
Changed
- Supported RPC version is now 0.7.0
- Default class hash in
account createandaccount deployhas been changed to cairo2 class hash
0.19.0
Forge
Added
replace_bytecodecheatcode- result of the call to the trace
- added
--build-profileflag to the--testcommand. Saves trace data and then builds profiles of test cases which pass and are not fuzz tests. You need cairo-profiler installed on your system. - dependency on the universal-sierra-compiler
binary, which will allow forge to be independent of sierra version
Changed
var(),read_txt(),read_json(),FileTrait::new(),declare()now use regular strings (ByteArray) instead of short strings (felt252)start_mock_call(),stop_mock_call(),L1Handlernow use selector (selector!()) instead of names
Cast
Changed
declare()now uses regular strings (ByteArray) instead of short strings (felt252)call()andinvoke()now require function selector (selector!()) instead of function name in scripts (sncast_std)
Removed
--path-to-scarb-tomloptional flag that allowed to specify the path to theScarb.tomlfile--deployedflag fromaccount addsubcommand
0.18.0
Forge
snforge require Scarb >= 2.5.4 to work - breaking changes to prepare for migration to USC
Added
- contract names to call trace
--max-n-stepsargument that allows setting own steps limit
Changed
- Unknown entry point error when calling a contract counts as a panic
- Cairo edition set to
2023_11
Fixed
- Calling Cairo 0 contract no longer cancels cheatcodes in further calls
Cast
Added
script initcommand to generate a template file structure for deployment scripts- Warning is emitted when executing sncast commands if the node's JSON-RPC version is incompatible
Changed
- to run a deployment script it is required to use
script runsubcommand
0.17.1
0.17.0
Forge
Added
get_call_tracelibrary function for retrieving call trace in tests
Changed
- Gas estimation is now aligned with the Starknet v0.13
Removed
snforge_std::PrintTrait- useprint!,println!macros and / orcore::debug::PrintTraitinstead
Fixed
- Gas used in constructors and handling of L1 messages is now properly included in total gas cost
Cast
Changed
- sncast tool configuration is now moved away from
Scarb.tomltosnfoundry.tomlfile. This file must be present in current or any parent directories in order to use profiles.
Added
--packageflag fordeclareandscriptsubcommands, that specifies scarb package to work withDebugandDisplayimpls for script subcommand responses - useprint!,println!macros instead of calling.print()
0.16.0
Forge
Added
- Bump to cairo 2.5.0
Changed
SafeDispatchers usages need to be tagged with#[feature("safe_dispatcher)](directly before usage), see the shamans post
0.15.0
Forge
Added
storeandloadcheatcodes--save-trace-dataflag tosnforge testcommand. Traces can be used for profiling purposes.
Changed
available_gasattribute is now supported (Scarb >= 2.4.4 is required)
Fixed
- Error message for tests that should panic but pass
Cast
Changed
- the 'pending' block is used instead of 'latest' as the default when obtaining the nonce
0.14.0
Forge
Added
Secp256k1andSecp256r1curves support forKeyPairinsnforge_std
Changed
- maximum number of computational steps per call set to current Starknet limit (3M)
meanandstd deviationfields are displayed for gas usage while running fuzzing tests- Cairo edition in
snforge_stdandsncast_stdset to2023_10 snforge_std::signaturemodule withstark_curve,secp256k1_curveandsecp256r1_curvesubmodules
Fixed
- Safe library dispatchers in test code no longer propagate errors when not intended to
0.13.1
Forge
Changed
- fields from
starknet::info::v2::TxInfoare now part ofTxInfoMockfromsnforge_std::cheatcodes::tx_info - consistent latest block numbers for each url are now used across the whole run when testing against forks
Fixed
- Parsing panic data from call contract result
Cast
Added
- add support for sepolia network
--yesoption toaccount deletecommand that allows to skip confirmation prompt
Changed
- Argument
max-feeinaccount deployis now optional
0.13.0
Changed
- Bump cairo to 2.4.0.
- Migrated test compilation and collection to Scarb, snforge should now be compatible with every Scarb version >= 2.4.0 unless breaking changes happen