What's Changed
- A new
excludeViewPureoption to disable testing of view and pure functions in property mode, except those with the test prefix, in #1552 (thanks @gustavo-grieco!) - The reason a test failed (e.g. a revert, or a property returning false) is now reported consistently across the text, JSON and UI outputs, including when no transactions are needed to reproduce the failure, in #1572 (thanks @gustavo-grieco!)
- Foundry reproducers are now generated for assertion failures that emit events in #1550 (thanks @gustavo-grieco!)
- The replay corpus is now distributed evenly across all fuzz workers in #1565 (thanks @rappie!), along with a fix for a divide-by-zero when running with
workers: 0in #1583 - A fix for a desync between the transaction sequence and the traces shown for shrunk reproducers in #1554 (thanks @rappie!)
- Two memory leaks were fixed, one in the constants dictionary in #1577 and one in the campaign event queue in #1587
- ANSI escape codes are now disabled when Echidna's output is not a TTY, which makes logs redirected to a file readable, in #1567 (thanks @gustavo-grieco!)
- The UI event listener is now started before the workers, so early events are no longer missed, in #1563 (thanks @rappie!)
- Deploying contracts to precompile addresses is now rejected with an error instead of silently misbehaving in #1585 (thanks @Ap4sh!)
- A fix for TLS handshake failures when fetching contracts from RPC providers that use certificate compression, such as Alchemy, by bumping
tlsto 2.2.2 in #1581 - A fix for libff header installation with CMake 4.3+ in #1573
- hevm has been updated to
4ca42fd5b2dd1344b7596775fe5fe6ac2d03021f(0.58.0 plus a few fixes) in #1575 and #1580 (full changelog: argotorg/hevm@8da7ea4...4ca42fd). The changes that affect Echidna directly are:- Dynamic arguments in symbolic mode: functions taking
bytes,stringor dynamic arrays are no longer skipped bysymExecand verification modes; hevm concretizes them up to a bounded length (Echidna uses 128), and reports a caveat when a counterexample could require longer inputs. - RPC retries with exponential backoff and a cooldown shared across workers, so transient network errors and rate limits (HTTP 429) from providers no longer abort on-chain fuzzing.
- Support for the
vm.expectRevertfamily of cheatcodes:expectRevert(),expectRevert(bytes),expectRevert(bytes4), theaddress-qualified variants, andexpectPartialRevert(bytes4[,address]). - New
assertApproxEqAbsandassertApproxEqRelcheatcodes foruint256andint256. - Foundry/Hardhat
console.logsupport: calls to the console address are intercepted and decoded in the execution traces Echidna prints, andEXTCODESIZEon the console address now returns 1 so contracts that check for code before logging are not skipped. - Assertion failures caused by a
Panicnow show their source location (file, line and code snippet) in traces. - Fixed the CREATE2 address computed while
pranking, which made deployments under pranking cheatcodes end up at the wrong address. - Enum types are now parsed correctly when reading the contract ABI.
- Cheatcode string arguments are decoded leniently instead of aborting the run on invalid UTF-8, so
vm.label,vm.setEnvandvm.envStringno longer crash on arbitrary byte sequences.
- Dynamic arguments in symbolic mode: functions taking
Full Changelog: v2.3.2...v2.3.3
This release was partially funded by the recent donation round on Giveth for Echidna; work like this is possible because of everyone who contributed.