EspressoSystems / EspressoSystems/espresso-network
Avoid logging error for recoverable case where leaf is not yet available on query service
- Dominant language
- Rust
- Stars
- 193
- Forks
- 177
- Avg merge
- 2d 4h
- Merged PRs (30d)
- 60
Description
This seems to happen reasonably frequently so in order to make reading the logs easier we can retry silently (or with INFO) for a few times and only log errors after some retries.
Currently we log
```
error synchronizing with HotShot contract: Availability: the requested leaf height 2274409 is out of range for the current ledger
```
From here: https://github.com/EspressoSystems/espresso-sequencer/blob/901e33805b277d68e481b7c0cbd90132dab2b4a6/sequencer/src/hotshot_commitment.rs#L99
We may also want to reduce the logging level in the hotshot query service to something less severe than `warn` because this is triggered quite frequently.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start at sequencer/src/hotshot_commitment.rs around line 99 and trace how the query service reports an out-of-range leaf during synchronization. Determine the existing retry and logging flow, then verify that recoverable cases remain quiet or informational until the stated retry threshold and that persistent failures still produce errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- backend, distributed-systems, observability
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100