Skip to content

Conversation

@ShiroObiJohn
Copy link
Contributor

What was wrong?

Fixes #238

How was it fixed?

implemented GET /eth/v1/validator/sync_committee_contribution endpoint.
added sync committee pool to manage sync committee messages and contributions.

To-Do

@shariqnaiyer
Copy link
Contributor

Could you please rebase this? I shall review it once you have.

git fetch upstream
git rebase upstream/master

@ShiroObiJohn ShiroObiJohn force-pushed the feat/beacon_api_validator_sync_committee_contribution branch from 18406c1 to 3fa423f Compare December 15, 2025 08:15
@ShiroObiJohn
Copy link
Contributor Author

Could you please rebase this? I shall review it once you have.

git fetch upstream
git rebase upstream/master

@shariqnaiyer rebased. Thank you!

@shariqnaiyer
Copy link
Contributor

Overall looks good, I wonder why sync committee pool is optional and is made none in most store initializations? Is that intentional?

@ShiroObiJohn ShiroObiJohn force-pushed the feat/beacon_api_validator_sync_committee_contribution branch from 3fa423f to 7b1dff7 Compare December 17, 2025 11:48
@ShiroObiJohn
Copy link
Contributor Author

Overall looks good, I wonder why sync committee pool is optional and is made none in most store initializations? Is that intentional?

Yes. Only some of sync committee related Beacon API endpoints need to access it.

@shariqnaiyer
Copy link
Contributor

shariqnaiyer commented Dec 25, 2025

https://github.com/ReamLabs/ream/blob/master/crates/networking/manager/src/gossipsub/handle.rs#L267-L295

            GossipsubMessage::SyncCommittee((sync_committee, subnet_id)) => {
                info!(
                    "Sync Committee received over gossipsub: root: {}",
                    sync_committee.tree_hash_root()
                );

                match validate_sync_committee(&sync_committee, beacon_chain, subnet_id, cached_db)
                    .await
                {
                    Ok(validation_result) => match validation_result {
                        ValidationResult::Accept => {
                            p2p_sender.send_gossip(GossipMessage {
                                topic: GossipTopic::from_topic_hash(&message.topic)
                                    .expect("invalid topic hash"),
                                data: sync_committee.as_ssz_bytes(),
                            });
                        }
                        ValidationResult::Reject(reason) => {
                            info!("Sync committee message rejected: {reason}");
                        }
                        ValidationResult::Ignore(reason) => {
                            info!("Sync committee message ignored: {reason}");
                        }
                    },
                    Err(err) => {
                        error!("Could not validate sync committee message: {err}");
                    }
                }
            }

We want to populate the sync committee pool. I believe we will have to add them once we see it in gossip messages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implement /eth/v1/validator/sync_committee_contribution

2 participants