Ethereum
¿Listo para usar esto en producción?
El plan gratuito cubre proyectos personales. El pago por uso escala sin necesidad de tarjeta.
Ethereum
El plan gratuito cubre proyectos personales. El pago por uso escala sin necesidad de tarjeta.
debug_getBadBlocks reports the blocks a geth-style Ethereum node tried to import but rejected as invalid. On Ethereum mainnet (chain ID 1, native coin ETH), every proposed block must pass execution-layer validation before it joins the canonical chain; anything that fails — a bad state root, an unexecutable transaction, a header that breaks the rules — gets discarded and recorded here. Call it over the TheRPC endpoint at https://ethereum.therpc.io/YOUR_API_KEY. The response is the running list of those rejected blocks observed since the node last started, each carrying its hash, decoded header, and raw RLP bytes for inspection.
Este método no acepta parámetros. Pasa un array vacío [].
| Tipo | Descripción |
|---|---|
| array | Array of objects, each with `{hash, block, rlp}` — `block` contains the decoded header fields and `rlp` is the raw RLP-encoded block. Returns an empty array if no bad blocks have been seen. |
Try it live in the Ethereum playground.
| Código | Mensaje | Causa |
|---|---|---|
-32601 | Method not found | debug namespace not enabled on the node, or client does not implement this method. |
-32601 instead of implementing it.