Proxy functionality: substitute IVault
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
import json
|
import json, os, logging
|
||||||
|
|
||||||
from .. import current_w3 as _current_w3
|
from .. import current_w3 as _current_w3
|
||||||
from .abi import abis
|
from .abi import abis
|
||||||
@@ -6,6 +6,9 @@ from .contract_proxy import ContractProxy
|
|||||||
|
|
||||||
|
|
||||||
def get_contract_data(name):
|
def get_contract_data(name):
|
||||||
|
if name == "Vault" and os.path.exists(f'../contract/out/I{name}.sol/I{name}.json') :
|
||||||
|
logging.warning("getting abi from IVault.json instead of Vault.json")
|
||||||
|
name = "IVault" # Special case for proxy Vault
|
||||||
with open(f'../contract/out/{name}.sol/{name}.json', 'rt') as file:
|
with open(f'../contract/out/{name}.sol/{name}.json', 'rt') as file:
|
||||||
return json.load(file)
|
return json.load(file)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user