Skip to content

chore(ethexe-consensus): Metric for last signed batch commitment#5237

Open
ecol-master wants to merge 4 commits intomasterfrom
kuzmindev/consensus-sign-metric
Open

chore(ethexe-consensus): Metric for last signed batch commitment#5237
ecol-master wants to merge 4 commits intomasterfrom
kuzmindev/consensus-sign-metric

Conversation

@ecol-master
Copy link
Member

No description provided.

@semanticdiff-com
Copy link

semanticdiff-com bot commented Mar 19, 2026

Review changes with  SemanticDiff

Changed Files
File Status
  ethexe/consensus/src/validator/coordinator.rs  37% smaller
  ethexe/common/src/mock.rs  19% smaller
  ethexe/consensus/src/validator/core.rs  1% smaller
  Cargo.lock Unsupported file format
  ethexe/consensus/Cargo.toml Unsupported file format
  ethexe/consensus/src/validator/mock.rs  0% smaller
  ethexe/consensus/src/validator/mod.rs  0% smaller
  ethexe/consensus/src/validator/participant.rs  0% smaller
  ethexe/consensus/src/validator/producer.rs  0% smaller

@ecol-master ecol-master changed the title chore(ethexe-consensus): Metrics for last signed batch commitment chore(ethexe-consensus): Metric for last signed batch commitment Mar 19, 2026
@ecol-master ecol-master marked this pull request as ready for review March 19, 2026 11:20
@ecol-master ecol-master added A0-pleasereview PR is ready to be reviewed by the team D8-ethexe ethexe-related PR labels Mar 19, 2026
@ecol-master ecol-master self-assigned this Mar 19, 2026
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request introduces a new metric to monitor validator activity within the ethexe-consensus module. By tracking the block number of the last signed batch commitment, it provides better visibility into the operational status and responsiveness of individual validators. This enhancement improves the overall observability of the consensus mechanism without altering its core logic.

Highlights

  • New Metric Introduced: Added a new metric, last_signed_commitment_block_number, to track the block number of the last batch commitment signed by a validator.
  • Metrics Integration: Integrated the metrics and metrics-derive crates into the ethexe-consensus module to enable custom metric reporting.
  • Validator Core Update: Modified the ValidatorCore struct to include a ValidatorMetrics instance, allowing validators to report their activity.
  • Batch Commitment Signing Metric: Updated the Coordinator and Participant logic to set the last_signed_commitment_block_number metric whenever a batch commitment is successfully signed.
  • Mocking Refactor: Refactored the SimpleBlockData mock creation in ethexe-common to delegate BlockHeader mocking to a dedicated BlockHeader::mock implementation, improving test utility.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@gemini-code-assist
Copy link
Contributor

Warning

Gemini is experiencing higher than usual traffic and was unable to create the review. Please try again in a few hours by commenting /gemini review.

mut ctx: ValidatorContext,
validators: ValidatorsVec,
batch: BatchCommitment,
block: SimpleBlockData,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not important

append debug_assert!(batch.block_hash == block.hash)

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

Labels

A0-pleasereview PR is ready to be reviewed by the team D8-ethexe ethexe-related PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants