Consensys / teku

Open-source Ethereum consensus client written in Java
https://consensys.io/teku
Apache License 2.0
663 stars 282 forks source link

Proposer Assign RPC Return 500 Error #8703

Open J1a-wei opened 6 days ago

J1a-wei commented 6 days ago

Hi Teku team, When slot miss. e.g. https://beaconcha.in/slot/10143104 Call Proposer Assign RPC. Teku client return 500 Internal Error.

/eth/v1/validator/duties/proposer/{epoch}

Teku Args:

- --network=${NETWORK}
- --data-path=/data
- --data-beacon-path=/data/beacon
- --data-storage-archive-frequency=${ARCHIVE_FREQUENCY}
- --data-storage-mode=archive
- --checkpoint-sync-url=${CHECKPOINT_URL}
- --ee-endpoint=http://reth:8551
- --ee-jwt-secret-file=/reth/jwt.hex
- --p2p-enabled=true
- --p2p-advertised-ip=${PUBLIC_IP}
- --p2p-advertised-port=${P2P_PORT}
- --rest-api-enabled=true
- --rest-api-host-allowlist=*
- --rest-api-interface=0.0.0.0
- --rest-api-port=8080
- --rest-api-cors-origins=false
lucassaldanha commented 6 days ago

Hi! Thanks for reporting this issue.

To clarify, are you calling the Validator API Get block proposer duties method externally? Or did your Validator node report the RPC error? Or are you saying that your validator missed the proposal because the duties method returned 500?

J1a-wei commented 6 days ago

Just calling the Validator API Get block proposer duties method externally @lucassaldanha

tbenr commented 5 days ago

I think he is saying that if the epoch begins with an empty slot, then the api fails. Going to check if it is the case.

tbenr commented 5 days ago

@J1a-wei I cannot replicate the issue based on what I understood from your description. Can you provide beacon node logs in the surrounding of the 500 error? Can you also provide the epoch parameter you where using in the query?

J1a-wei commented 5 days ago

HI @tbenr Sorry, I synced from the most recent checkpoint, and the previous data has been deleted.

I suspect that if the first slot of the epoch is missed, the RPC(/eth/v1/validator/duties/proposer/{epoch}) cannot be called.

When I checked the logs, it's highly likely that there wasn't any meaningful log because the debug log level wasn't enabled.

tbenr commented 2 days ago

@J1a-wei 500 errors are bad errors that do not require debug level logging to have more info. If there were no error logs it, is it possible that the 500 error you're talking about was a 503?

image

It happens when you try to hit the endpoint while the node is syncing (like when you start from a checkpoint sync)