Beacon API: serve states/{state_id}/committees and blocks/{block_id}/attestations

Offen
#858 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Maintainer antworten meist innerhalb von 6 Tagen

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
3/5
Geschätzter Aufwand
1-2 Tage
Anfängerfreundlichkeit
56/100
Issue-Typ
Feature
Klarheit
Klar beschrieben
Aktivitätsstatus
Aktiv
Tech-Stack
rust
Bereich
api

Rechercherichtung

The payload names only docs/rpc.md; start by locating the existing beacon API route table and the committee shuffling the node already computes during attestation validation. Implement GET /eth/v1/beacon/states/{state_id}/committees with the epoch, index and slot filters, then GET /eth/v2/beacon/blocks/{block_id}/attestations honouring Eth-Consensus-Version, and add both to docs/rpc.md. Done means xatu sentry, assertoor and slashoor receive real data instead of 404s.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

Problem. GET /eth/v1/beacon/states/{state_id}/committees and GET /eth/v2/beacon/blocks/{block_id}/attestations are not served. Three of ethereum-package's tools depend on them. These findings come from reading each tool's source against main (b2722cfd); nothing was run.

  • xatu sentry (one per participant): its duties service fetches states/head/committees.
    • On the 404 it retries for 15 minutes and then never reports ready.
    • Every event handler checks that readiness, so the sentry stays up but drops every event (head, block, attestation, data column, proposer duties) and logs an error for each.
    • Removing attestation from its subscriptions does not avoid this: the package's template also enables committee fetching.
  • assertoor: check_consensus_attestation_stats asks for committees by state root. The task never records a result, so the bundled stability-check playbook never passes.
    • On an ethlambda-only network the state-root lookup in lambdaclass/ethlambda#857 is needed as well.
    • In a mixed network it can pass by chance, when the request goes to another client.
  • slashoor: it reads blocks/{id}/attestations and the committees to find double and surround votes.
    • On 404s it processes zero attestations and logs nothing, so it misses every attester slashing.
    • Proposer slashings still work.

Fix.

  • Serve GET /eth/v1/beacon/states/{state_id}/committees, with the epoch, index and slot filters, from the committee shuffling the node already computes for attestation validation.
  • Serve GET /eth/v2/beacon/blocks/{block_id}/attestations, with Eth-Consensus-Version.
  • Document both in docs/rpc.md.
Vorherrschende Sprache
Rust
Sterne
86
Forks
34
Ø Merge
9 T. 20 Std.
Gemergte PRs (30 T.)
77

Entwicklungsumgebung

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus lambdaclass/ethlambda

Alle Issues in lambdaclass/ethlambda

Ähnliche Issues

Weitere Issues zu Rust

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.