A Python library for interacting with Ethereum blockchain
Overall
score
88%
Evaluation — 88%
↑ 1.01xAgent success when using this tile
A utility to check if an Ethereum node is synchronized with the blockchain network.
Build a function that queries whether an Ethereum node is currently synchronizing with the network and returns detailed synchronization information when available.
Create a function that takes synchronization data and formats it into a human-readable progress report.
@generates
from typing import Union, Dict, Any, Optional
def get_sync_status(provider_uri: str) -> Union[bool, Dict[str, Any], None]:
"""
Query the synchronization status of an Ethereum node.
Args:
provider_uri: The URI of the Ethereum node provider (e.g., HTTP endpoint)
Returns:
- False if the node is fully synchronized
- Dict with keys 'startingBlock', 'currentBlock', 'highestBlock' if syncing
- None if unable to connect or query the node
"""
pass
def format_sync_progress(sync_status: Union[bool, Dict[str, Any], None]) -> str:
"""
Format synchronization status into a human-readable message.
Args:
sync_status: The sync status returned from get_sync_status()
Returns:
A formatted string describing the sync status
"""
passProvides Python interface for interacting with Ethereum blockchain nodes.
@satisfied-by
Install with Tessl CLI
npx tessl i tessl/pypi-web3docs
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10