Closed fubuloubu closed 1 year ago
i've identified where the issue comes from:
masterCopy()
revertsget_virtual_machine_error
of a not yet initialized contract.enrich_error
, which tries to get the abi, so it falls into the inifinite loop.the solution could be to either propagate skip_trace=True
up to enrich_error
or better not try getting partially-initialized abis from the error handler.
this can be done but acquiring a lock when initializing a contract and skip requesting the abi in downstream handlers if there is an active lock for the desired contract.
Environment information
ape
and plugin versions:What went wrong?
The Permit2 implementation contract (
0x000000000022D473030F116dDEE9F6B43aC78BA3
on almost all networks) causes an infinite loop inside of our proxy info routineHow can it be fixed?
I'm guessing that the bytecode has a matching sequence to one of the regex comparisons we are doing, so it should be required to do some additional validation on the length of the bytecode to avoid false positives