-
Notifications
You must be signed in to change notification settings - Fork 247
test: enable force inclusion, re-enable fi e2e and add fi benchmarks #3005
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
The latest Buf updates on your PR. Results from workflow CI / buf-check (pull_request).
|
Summary of ChangesHello @julienrbrt, 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 focuses on enabling and validating the 'force inclusion' functionality within the system. It removes a previous block in the configuration validation that prevented the feature from being active and subsequently re-enables the comprehensive suite of end-to-end tests designed to verify its correct operation across various EVM components. Highlights
🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console. Using Gemini Code AssistThe 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
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 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. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
|
Claude finished @julienrbrt's task in 2m 40s —— View job Comprehensive Code ReviewI've completed a thorough review of this PR which enables force inclusion functionality. Below is my detailed feedback organized by category. SummaryThis PR successfully enables the force inclusion feature by:
The changes are well-structured and the test coverage is excellent. However, there are several areas that need attention. Critical Issues1. Missing Test Coverage for Config Validation 🔴File: The PR removes the temporary block that prevented force inclusion from being enabled: if len(c.DA.GetForcedInclusionNamespace()) > 0 {
if err := validateNamespace(c.DA.GetForcedInclusionNamespace()); err != nil {
return fmt.Errorf("could not validate forced inclusion namespace (%s): %w", c.DA.GetForcedInclusionNamespace(), err)
}
}Issue: Codecov reports 0% patch coverage for these 2 lines. The namespace validation logic for force inclusion is now active but completely untested. Impact: If there's a bug in the namespace validation or someone provides an invalid namespace format, it won't be caught by tests. Recommendation: Add unit tests in
Code Quality Issues2. Flag Consistency - Prefix Usage
|
| Component | Coverage | Assessment |
|---|---|---|
| Config validation | ❌ 0% | Needs tests |
| E2E sequencer force inclusion | ✅ Good | Complete scenario |
| E2E full node force inclusion | ✅ Good | Complete scenario |
| E2E malicious sequencer detection | ✅ Excellent | Security property validated |
| FilterTxs benchmarks | ✅ Good | Comprehensive scenarios |
Overall test quality: High, but config validation tests are missing.
Recommendations Summary
Must Fix (Blocking)
- ✅ Add unit tests for forced inclusion namespace validation (0% coverage)
Should Fix (Recommended)
⚠️ Resolve flag prefix consistency (evnode.vsrollkit.)⚠️ Document or validate epoch=2 safety for testing⚠️ Document grace period calculation and detection timing
Nice to Have (Optional)
- 💡 Extract test constants (forced-inc namespace, epoch values)
- 💡 Refactor common sequencer setup code
- 💡 Add benchmark for structurally-valid but invalid transactions
- 💡 Consider per-transaction force inclusion flag for future optimization
Conclusion
This is a well-implemented feature enablement with excellent E2E test coverage and comprehensive benchmarks. The security properties are properly tested, particularly the malicious sequencer detection scenario.
Primary concern: The 0% patch coverage on the namespace validation code. This must be addressed before merging.
Secondary concerns: Flag consistency and test parameter documentation.
Once the config validation tests are added and flag prefix is standardized, this PR will be in excellent shape. The force inclusion feature appears production-ready from a test coverage perspective.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request enables the force inclusion feature. The changes in pkg/config/config.go correctly re-enable the validation logic for the forced inclusion namespace, and the changes in test/e2e/evm_force_inclusion_e2e_test.go re-enable the end-to-end tests for this feature by removing t.Skip() calls. The changes are straightforward and effectively achieve the goal of activating the force inclusion functionality and its associated tests. The pull request title also mentions the addition of force inclusion benchmarks, but no new benchmark files were found in the changes; this might be planned for a subsequent pull request.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3005 +/- ##
==========================================
- Coverage 58.04% 57.91% -0.13%
==========================================
Files 110 110
Lines 10522 10523 +1
==========================================
- Hits 6107 6094 -13
- Misses 3764 3778 +14
Partials 651 651
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
d0bab1c to
287ccc4
Compare
ref: #2965 (comment)
ref: #2982 (comment)