eth-brownie / brownie

A Python-based development and testing framework for smart contracts targeting the Ethereum Virtual Machine.

Home Page:https://eth-brownie.readthedocs.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Unable to determine error_code and test stops

YoshihitoAso opened this issue · comments

Environment information

  • brownie Version: 1.20.2
  • ganache-cli Version: 7.9.2
  • solc Version: 0.8.23
  • Python Version: 3.11
  • OS: osx/linux

What was wrong?

In my test, I use brownie.reverts(revert_msg="Integer overflow") to determine the error message, but this process stops with the current latest eth-brownie (v1.20.2) .

After analyzing the cause, processing stopped at the following part.

How can it be fixed?

I haven't been able to investigate why it's been working fine so far, but I think this code should be implemented like this, for example:

error_code = int(HexBytes(data[10:]).hex(), 16)