PatrickAlphaC / brownie_fund_me

26 stars 64 forks source link

ValueError: execution reverted: VM Exception while processing transaction: revert Please Help #47

Closed Deamonk1 closed 2 years ago

Deamonk1 commented 2 years ago

Hi please i ran into a problem while deploying Brownie Fund_and_withdraw.py script through ganache-local network already spent 3 days trying to find a quick solution. when i run brownie run scripts/deploy.py --network ganache-local. my script ran successfully but when i try interact with added Fund_and_withdraw.py script i got this error

Running 'scripts/fund_and_withdraw.py::main'... File "brownie/_cli/run.py", line 51, in main return_value, frame = run( File "brownie/project/scripts.py", line 110, in run return_value = f_locals[method_name](*args, *kwargs) File "./scripts/fund_and_withdraw.py", line 22, in main fund_me() File "./scripts/fund_and_withdraw.py", line 8, in fund_me entrance_fee = fund_me.getEntranceFee() File "brownie/network/multicall.py", line 115, in _proxy_call result = ContractCall.call(args, *kwargs) # type: ignore File "brownie/network/contract.py", line 1902, in call return self.call(args, block_identifier=block_identifier, override=override) File "brownie/network/contract.py", line 1693, in call raise VirtualMachineError(e) from None File "brownie/exceptions.py", line 93, in init raise ValueError(str(exc)) from None ValueError: execution reverted: VM Exception while processing transaction: revert

I also checked ganache cli Logs here's the output :

eth_call[8:54:53 PM] > {[8:54:53 PM] > "jsonrpc": "2.0",[8:54:53 PM] > "method": "eth_call",[8:54:53 PM] > "params": [[8:54:53 PM] > {[8:54:53 PM] > "to": "0x8309ABC2528f652823Cad736d35B612fcF6aaBc6",[8:54:53 PM] > "data": "0x09bc33a7"[8:54:53 PM] > },[8:54:53 PM] > "latest"[8:54:53 PM] > ],[8:54:53 PM] > "id": 7[8:54:53 PM] > }[8:54:53 PM] < {[8:54:53 PM] < "id": 7,[8:54:53 PM] < "jsonrpc": "2.0",[8:54:53 PM] < "error": {[8:54:53 PM] < "message": "VM Exception while processing transaction: revert",[8:54:53 PM] < "code": -32000,[8:54:53 PM] < "data": {[8:54:53 PM] < "0x6656326ec950a3a1b1cfc3103cc1bfb427e74c8045c75e278525ac33a46868c4": {[8:54:53 PM] < "error": "revert",[8:54:53 PM] < "program_counter": 995,[8:54:53 PM] < "return": "0x"[8:54:53 PM] < },[8:54:53 PM] < "stack": "RuntimeError: VM Exception while processing transaction: revert\n at Function.RuntimeError.fromResults (/Applications/Ganache.app/Contents/Resources/static/node/node_modules/ganache-core/lib/utils/runtimeerror.js:94:13)\n at /Applications/Ganache.app/Contents/Resources/static/node/node_modules/ganache-core/lib/blockchain_double.js:568:26",[8:54:53 PM] < "name": "RuntimeError"[8:54:53 PM] < }

Please Any idea on how to solve this . Thanks in advance

Screen Shot 2022-06-29 at 3 21 44 AM Screen Shot 2022-06-29 at 3 36 59 AM
PatrickAlphaC commented 2 years ago

Could you make this on the full repo? Thanks!

https://github.com/smartcontractkit/full-blockchain-solidity-course-py

Deamonk1 commented 2 years ago

Hi Patrick Thanks for the reply. I've seen some other people running into this but their fixes did not work for me.

I asked this question in the main repo: #1560 Any idea on how to solve this problem Thanks