crytic / echidna

Ethereum smart contract fuzzer
https://secure-contracts.com/program-analysis/echidna/index.html
GNU Affero General Public License v3.0
2.74k stars 368 forks source link

[Bug-Candidate]: vm.startPrank() not working #1308

Closed 0xJoichiro closed 3 weeks ago

0xJoichiro commented 1 month ago

Describe the issue:

VM failed for unhandled reason, BadCheatCode 0x6447d56. This shouldn't happen. Please file a ticket with this error message and steps to reproduce! Stack trace: call HEVM::startPrankXD(0x000000000000000000000000000000000001E240)

Code example to reproduce the issue:

any basic code that uses vm.startPrank()

Version:

Echidna 2.2.4

Relevant log output:

VM failed for unhandled reason, BadCheatCode 0x6447d56. This shouldn't happen. Please file a ticket with this error message and steps to reproduce! Stack trace: call HEVM::startPrankXD(0x000000000000000000000000000000000001E240)
ggrieco-tob commented 1 month ago

startPrank support is coming. It is implemented in hevm, but we haven't upgraded yet.

0xJoichiro commented 1 month ago

@ggrieco-tob undertood,actually is saw #1229 and it was ended with as it works therefore had to ask.We can close this if you want now

arcz commented 1 month ago

Are you sure you are calling startPrank? The trace shows startPrankXD.

0xJoichiro commented 1 month ago

@arcz yes sir I did call startPrank(),as i saw the same trace message.Cross checked on my part have been fuzzing using echidna and its been an issue converting foundry tests into echidna ones

ggrieco-tob commented 1 month ago

Can you try using echidna from master?

elopez commented 3 weeks ago

Echidna 2.2.5 should have startPrank, with the caveat that CREATEs don't get pranked yet, hevm upstream is tracking it in https://github.com/ethereum/hevm/pull/564 -- let us know if you still experience issues after you upgrade though!