-
Notifications
You must be signed in to change notification settings - Fork 238
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problem: JSON-RPC depends on setting in client.toml #390
Comments
I don't reproduce the issue on main branch, what I do:
>>> w3 = web3.Web3(provider=web3.HTTPProvider('http://localhost:26651'))
>>> w3.eth.get_block('latest')
AttributeDict({'baseFeePerGas': 716, 'difficulty': 0, 'extraData': HexBytes('0x'), 'gasLimit': 4294967295, 'gasUsed': 0, 'hash': HexBytes('0xc19485569d1f27cd6ec9a9ffa916d7ef9829546eaad71d8e20e748be05fd867b'), 'logsBloom': HexBytes('0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'), 'miner': '0x38B4089F7762E0C20E9BeD8e991E074550Ef5a52', 'mixHash': HexBytes('0x0000000000000000000000000000000000000000000000000000000000000000'), 'nonce': HexBytes('0x0000000000000000'), 'number': 106, 'parentHash': HexBytes('0xdce399b828bb9626241c4512a3846ebde0ad6b5eaa003efe2953081cb26469a0'), 'receiptsRoot': HexBytes('0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421'), 'sha3Uncles': HexBytes('0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347'), 'size': 699, 'stateRoot': HexBytes('0x3b1e365bc164f966240d601368c1e397bd5826ef7e030f68ca97bd6e720a1dd0'), 'timestamp': 1647069257, 'totalDifficulty': 0, 'transactions': [], 'transactionsRoot': HexBytes('0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421'), 'uncles': []}) |
I just tried a few more times and it is exactly as I described. I'm using 0.6.5
client.toml for reference
|
did you disable the rest-api and grpc server? in that case it doesn't use the "local" client. try enable the grpc or API server. EDIT: I just reproduced the same issue by disable both grpc and API servers. |
will be fixed by evmos/ethermint#988. |
Thanks @yihuang for fixing this so quickly! Your right, I did disable both api and grpc as you mentioned. |
Describe the bug
If all settings are default, there is no issue. However, if
laddr = "tcp://0.0.0.0:26657"
is modified inconfig.toml
andnode = "tcp://localhost:26657"
not updated inclient.toml
, then json-rpc will have issues.I haven't fully tested, but I used web3.py and tried to request
w3.eth.get_block(block_identifier='latest')
andweb3.exceptions.BlockNotFound: Block with id: 'latest' not found
will be thrown. This was resolved whenclient.toml
was configured to matched laddr inconfig.toml
To Reproduce
Web3 code can be provided on request.
Expected behavior
I would expect the json-rpc on the node to read the node config from
config.toml
instead ofclient.toml
Additional context
Problem might be from Tharsis
The text was updated successfully, but these errors were encountered: