ethereum-optimism / ethereum-optimism/specs

Rm redundant error codes

Open
#686 2 comments 0 reactions 1 assignee Claimed by @rose2221 View on GitHub
A-rpc A-supervisor C-debt C-good-first-issue H-interop
Dominant language
Python
Stars
178
Forks
206
Avg merge
5d 2h
Merged PRs (30d)
6

Description

Remove redundant supervisor RPC error codes. Instead the error code section should mention that supervisor impls should refer to https://ethereum-json-rpc.com/errors to find a suitable catch all variant for errors which don't belong to any of the given protocol specific error codes.
https://github.com/ethereum-optimism/specs/blob/main/specs/interop/supervisor.md#protocol-specific-error-codes

Some codes seem to be only used internally by Go implementation, for example this appears to be the case for
- `ITER_STOP` https://github.com/ethereum-optimism/specs/blob/main/specs/interop/supervisor.md#-321100-out_of_scope (needs investigation to confirm if this is only used internally)
Others are general to any protocol and not specifically related to xmessage validation
- `UNINITIALIZED_CHAIN_DATABASE` https://github.com/ethereum-optimism/specs/blob/main/specs/interop/supervisor.md#-320400-uninitialized_chain_database
- `CANNOT_GET_PARENT_OF_FIRST_BLOCK_IN_DB` https://github.com/ethereum-optimism/specs/blob/main/specs/interop/supervisor.md#-321200-cannot_get_parent_of_first_block_in_db

The list should only contain errors specific to the interop consensus checks implemented by the supervisor.

Ref https://github.com/paradigmxyz/reth/pull/15944#discussion_r2062943685

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.