Skip to content

fix(ci,tooling): include json-loader in coverage reports#2975

Merged
danceratopz merged 1 commit into
ethereum:forks/amsterdamfrom
SamWilsn:coverage
Jun 17, 2026
Merged

fix(ci,tooling): include json-loader in coverage reports#2975
danceratopz merged 1 commit into
ethereum:forks/amsterdamfrom
SamWilsn:coverage

Conversation

@SamWilsn

Copy link
Copy Markdown
Contributor

🗒️ Description

Coverage wasn't being collected for json_loader, so files like genesis.py were showing as 0%.

Cute Animal Picture

Put a link to a cute animal picture inside the parenthesis-->

@SamWilsn SamWilsn requested a review from danceratopz June 10, 2026 17:48
@codecov

codecov Bot commented Jun 10, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 93.02%. Comparing base (b314d18) to head (b5fe3e3).
⚠️ Report is 2 commits behind head on forks/amsterdam.

Additional details and impacted files
@@                 Coverage Diff                 @@
##           forks/amsterdam    #2975      +/-   ##
===================================================
+ Coverage            90.13%   93.02%   +2.89%     
===================================================
  Files                  620      620              
  Lines                36641    38714    +2073     
  Branches              3311     3311              
===================================================
+ Hits                 33026    36015    +2989     
+ Misses                3019     1813    -1206     
- Partials               596      886     +290     
Flag Coverage Δ
unittests 93.02% <ø> (+2.89%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@danceratopz danceratopz changed the title fix(ci): include json-loader in coverage reports fix(ci,tooling): include json-loader in coverage reports Jun 11, 2026
@danceratopz danceratopz added C-bug Category: this is a bug, deviation, or other problem A-tooling Area: Improvements or changes to auxiliary tooling such as uv, ruff, mypy, ... A-ci Area: Continuous Integration labels Jun 11, 2026

@danceratopz danceratopz left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Hey Sam, the changes look good, but, assuming it's the 90.53% number (below is copied from the codecov bot comment) you want to improve, we haven't achieved that goal yet.

@@                 Coverage Diff                 @@
##           forks/amsterdam    #2975      +/-   ##
===================================================
- Coverage            90.53%   88.81%   -1.72%     
===================================================
  Files                  535      620      +85     
  Lines                32893    38706    +5813     
  Branches              3021     3310     +289     
===================================================
+ Hits                 29780    34378    +4598     
- Misses                2595     3520     +925     
- Partials               518      808     +290     

This is because ./tests/json_loader/ imports more modules that weren't previously imported by running just fill. So although we gain coverage for src/ethereum/genesis.py, we lose coverage absolutely due to these new imports.

Looking into it, the coverage report now newly includes ./src/ethereum/forks/spurious_dragon/ and ./src/ethereum/forks/tangerine_whistle/ which leads to the coverage drop. json_loader imports these forks, but fill doesn't: These forks are currently configured to be ignored by fill (ignore=True), so didn't previously get imported or contribute to the coverage report:

class TangerineWhistle(
DAOFork,
ignore=True,
ruleset_name="TANGERINE",
):
"""TangerineWhistle fork (EIP-150)."""
pass

Wdyt? Should we configure codecov to ignore these forks, too? That seems reasonable to me. We could add them here:

[tool.coverage.run]
omit = [
"*/ethereum/forks/*_glacier/*",
"*/ethereum/forks/dao_fork/*",
"*/ethereum/forks/bpo*/*",
]

Comment thread Justfile

@danceratopz danceratopz left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@danceratopz danceratopz merged commit 7ccf649 into ethereum:forks/amsterdam Jun 17, 2026
18 checks passed
@SamWilsn SamWilsn deleted the coverage branch June 17, 2026 13:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-ci Area: Continuous Integration A-tooling Area: Improvements or changes to auxiliary tooling such as uv, ruff, mypy, ... C-bug Category: this is a bug, deviation, or other problem

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants