Answer the question
In order to leave comments, you need to log in
Why does the getBalance method in the web3.py library not work?
Error with balance = web3.eth.getBalance(k) Shortened
as best I could.
web3.py version 5.12.0
import web3
from web3 import Web3
w3 = Web3(Web3.IPCProvider())
balance = web3.eth.getBalance(k)
Traceback (most recent call last):
File "C:/Users/user/Desktop/storage.py", line 26, in <module>
class check():
File "C:/Users/user/Desktop/storage.py", line 54, in check
balance = web3.eth.getBalance(k)
AttributeError: module 'web3.eth' has no attribute 'getBalance'
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question