'eth-brownie: Deployed contract returning as transaction receipt instead of the contract itself. I cannot grab the contract from the address or alias
I deployed a token on the BSC network transaction
it saved the object as a transaction receipt
it is not returning the contract object, as it shows in the docs.
I also cannot grab the contract from the address. I have a mint function in the contract that I am trying to run. I cannot do this with just the transaction receipt can I?
When I tested on ganache test network, it returns a contract object. I was able to run the mint function just fine! but on the live network I am having some issues.
Thank you for your time.
Solution 1:[1]
Adding a "required_confs" key to the tx data should solve this.
should_be_instance_of_contract = contract.deploy(
{"from": account, 'required_confs': 3},
publish_source=True
)
vs.
should_be_tx_receipt = contract.deploy(
{"from": account},
publish_source=True
)
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | Nico |