Skip to content
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

chore: Fall back to legacy config loading in migration startup #17433

Merged
merged 1 commit into from
Jan 17, 2025

Conversation

mhess-swl
Copy link
Contributor

@mhess-swl mhess-swl commented Jan 17, 2025

In the case where we don't have a genesis-network.json file present at startup, DiskStartupNetworks.genesisOrThrow(...) correctly falls back to loading config.txt etc. to produce the Network object. We need to do the same for migration cases, so this PR adds that same fallback to DiskStartupNetworks.migrationOrThrow().

Closes #17257

Signed-off-by: Matt Hess <matt.hess@swirldslabs.com>
Copy link

Coverage summary from Codacy

See diff coverage on Codacy

Coverage variation Diff coverage
+0.00% (target: -1.00%) 100.00%
Coverage variation details
Coverable lines Covered lines Coverage
Common ancestor commit (6f7e468) 96991 70490 72.68%
Head commit (3ac173d) 96992 (+1) 70493 (+3) 72.68% (+0.00%)

Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: <coverage of head commit> - <coverage of common ancestor commit>

Diff coverage details
Coverable lines Covered lines Diff coverage
Pull request (#17433) 2 2 100.00%

Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: <covered lines added or modified>/<coverable lines added or modified> * 100%

See your quality gate settings    Change summary preferences

Codacy stopped sending the deprecated coverage status on June 5th, 2024. Learn more

Copy link

codecov bot commented Jan 17, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 68.74%. Comparing base (6f7e468) to head (3ac173d).
Report is 4 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff            @@
##               main   #17433   +/-   ##
=========================================
  Coverage     68.74%   68.74%           
+ Complexity    22591    22590    -1     
=========================================
  Files          2610     2610           
  Lines         97208    97209    +1     
  Branches      10129    10129           
=========================================
+ Hits          66824    66828    +4     
+ Misses        26567    26565    -2     
+ Partials       3817     3816    -1     
Files with missing lines Coverage Δ
.../com/hedera/node/app/info/DiskStartupNetworks.java 83.54% <100.00%> (+0.10%) ⬆️

... and 1 file with indirect coverage changes

Impacted file tree graph

Copy link
Contributor

@tinker-michaelj tinker-michaelj left a comment

Choose a reason for hiding this comment

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

LGMT, tyvm @mhess-swl !

@tinker-michaelj tinker-michaelj merged commit 0129e3a into main Jan 17, 2025
67 checks passed
@tinker-michaelj tinker-michaelj deleted the 17257-migration-fallback branch January 17, 2025 21:52
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.

Enhance DiskStartupNetworks to support asset loading via config.txt and PEM files
2 participants