Skip to content

Lesson 9: Error: VM Exception while processing transaction: reverted with an unrecognized custom error #5507

Answered by alymurtazamemon
AmethRP asked this question in Q&A
Discussion options

You must be logged in to vote

@AmethRP The solution I just was for the latest version of chai matcher which comes built-in with hardhat-toolbox dependency.

But for your version this is working;

await expect(raffle.enterRaffle({ value: raffleEntranceFee })).to.be.revertedWith(
    "Raffle__NotOpen"
)

Try to remove both .lock files and node_modules folder and reinstall dependencies and then retry.

Replies: 1 comment 11 replies

Comment options

You must be logged in to vote
11 replies
@AmethRP
Comment options

@alymurtazamemon
Comment options

@AmethRP
Comment options

@alymurtazamemon
Comment options

Answer selected by AmethRP
@AmethRP
Comment options

@alymurtazamemon
Comment options

@AmethRP
Comment options

@Glow-in-the-dark
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants