Skip to content

ci: exclude DPP state transition boilerplate from coverage#3358

Merged
QuantumExplorer merged 2 commits into
v3.1-devfrom
ci/codecov-exclude-dpp-boilerplate
Mar 17, 2026
Merged

ci: exclude DPP state transition boilerplate from coverage#3358
QuantumExplorer merged 2 commits into
v3.1-devfrom
ci/codecov-exclude-dpp-boilerplate

Conversation

@QuantumExplorer
Copy link
Copy Markdown
Member

@QuantumExplorer QuantumExplorer commented Mar 17, 2026

Summary

  • Exclude ~3,900 lines of pure boilerplate from Codecov tracking in rs-dpp/src/state_transition/
  • Errors: thiserror enum definitions with no logic
  • Traits: interface definitions with no default implementations
  • Accessors: thin field getter/setter trait impls
  • Field constants: fields.rs, common_fields.rs — pure const definitions
  • Type metadata: types.rssignature_property_paths(), identifiers_property_paths(), etc.
  • Version dispatch: version.rs — single-arm match statements
  • Factory/types: enum definitions with derives only

Business logic files (v0_methods, validation, serialization, signing, state_transition_like) remain tracked.

Test plan

  • Codecov config is valid (CI will validate on upload)
  • Coverage numbers should tick up slightly as denominator shrinks

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Chores
    • Updated code coverage reporting configuration to refine which files are excluded from coverage metrics.

Exclude ~3,900 lines of pure boilerplate from Codecov tracking in
rs-dpp/src/state_transition/:

- errors/: thiserror enum definitions
- traits/: trait interfaces with no default implementations
- accessors/: thin field getter/setter traits
- fields.rs, common_fields.rs: constant definitions
- types.rs: metadata trait impls (signature_property_paths, etc.)
- version.rs: version dispatch match statements
- state_transition_factory.rs, state_transition_types.rs: enum definitions

This improves signal-to-noise in coverage reports by focusing on actual
business logic (v0_methods, validation, serialization, signing).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions github-actions Bot added this to the v3.1.0 milestone Mar 17, 2026
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Mar 17, 2026

Warning

Rate limit exceeded

@QuantumExplorer has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 20 minutes and 44 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 177cd581-a440-43b3-9800-f53a76738f56

📥 Commits

Reviewing files that changed from the base of the PR and between 6a9e8c1 and 8c8ccf3.

📒 Files selected for processing (1)
  • .codecov.yml
📝 Walkthrough

Walkthrough

The pull request updates the Codecov configuration file to exclude additional state transition-related files from code coverage reporting, including error definitions, trait declarations, accessor modules, and various state transition implementation files.

Changes

Cohort / File(s) Summary
Codecov Configuration
.codecov.yml
Updated ignore patterns to exclude 9 additional state transition-related files and directories from coverage reporting: error types, trait definitions, accessor modules, and state transition factory/type files.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Poem

🐰 Hopping through code, with coverage in sight,
We've marked those state transitions—not quite the right light!
Errors and traits, excluded with care,
The codecov reports now skip what's not there! ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and specifically summarizes the main change: excluding DPP state transition boilerplate from Codecov coverage tracking.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch ci/codecov-exclude-dpp-boilerplate
📝 Coding Plan
  • Generate coding plan for human review comments

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In @.codecov.yml:
- Around line 30-31: The coverage exclusions are too broad—rules like excluding
"traits/**", "state_transitions/**/accessors/**", and the current exclusion for
state_transition_factory.rs are hiding logic (e.g.,
state_transition_witness_validation.rs, batch_transition/accessors/mod.rs,
state_transition_factory.rs). Tighten the .codecov.yml patterns to only omit
true boilerplate/generated files (for example exclude specific filenames like
mod.rs or a generated/ folder) and remove the broad "traits/**" and
"accessors/**" patterns so that files containing logic such as
state_transition_witness_validation, batch_transition/accessors/mod.rs, and
state_transition_factory.rs remain tracked.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 45ce569d-6e3a-4f71-a802-b9c1fab2c0bc

📥 Commits

Reviewing files that changed from the base of the PR and between 1caaa24 and 6a9e8c1.

📒 Files selected for processing (1)
  • .codecov.yml

Comment thread .codecov.yml
Comment on lines +30 to +31
- "packages/rs-dpp/src/state_transition/traits/**"
- "packages/rs-dpp/src/state_transition/state_transitions/**/accessors/**"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

Coverage exclusions are too broad and remove logic-heavy code from tracking.

Line 30 (traits/**), Line 31 (accessors/**), and Line 37 (state_transition_factory.rs) exclude files that contain executable logic (e.g., state_transition_witness_validation.rs:52-89, batch_transition/accessors/mod.rs:44-115, state_transition_factory.rs:8-20). This undermines coverage signal instead of only removing boilerplate.

Suggested config adjustment
-  - "packages/rs-dpp/src/state_transition/traits/**"
-  - "packages/rs-dpp/src/state_transition/state_transitions/**/accessors/**"
   - "packages/rs-dpp/src/state_transition/state_transitions/**/fields.rs"
   - "packages/rs-dpp/src/state_transition/state_transitions/**/common_fields.rs"
   - "packages/rs-dpp/src/state_transition/state_transitions/**/types.rs"
   - "packages/rs-dpp/src/state_transition/state_transitions/**/version.rs"
   - "packages/rs-dpp/src/state_transition/state_transition_types.rs"
-  - "packages/rs-dpp/src/state_transition/state_transition_factory.rs"
+  # Keep logic-bearing modules covered; if needed, exclude only explicit
+  # boilerplate trait/accessor files after listing them individually.

Also applies to: 37-37

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.codecov.yml around lines 30 - 31, The coverage exclusions are too
broad—rules like excluding "traits/**", "state_transitions/**/accessors/**", and
the current exclusion for state_transition_factory.rs are hiding logic (e.g.,
state_transition_witness_validation.rs, batch_transition/accessors/mod.rs,
state_transition_factory.rs). Tighten the .codecov.yml patterns to only omit
true boilerplate/generated files (for example exclude specific filenames like
mod.rs or a generated/ folder) and remove the broad "traits/**" and
"accessors/**" patterns so that files containing logic such as
state_transition_witness_validation, batch_transition/accessors/mod.rs, and
state_transition_factory.rs remain tracked.

@QuantumExplorer QuantumExplorer merged commit e32ecda into v3.1-dev Mar 17, 2026
15 checks passed
@QuantumExplorer QuantumExplorer deleted the ci/codecov-exclude-dpp-boilerplate branch March 17, 2026 05:17
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.

1 participant