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

fix: fetch stable version #328

Merged
merged 7 commits into from
Nov 7, 2024
Merged

fix: fetch stable version #328

merged 7 commits into from
Nov 7, 2024

Conversation

AlexD10S
Copy link
Collaborator

This PR addresses the sorting issue identified in: #325 where versioned tags were prioritized over stable2409 in the pop up parachain process.

Changes

  • Updated the logic to use this improved sorting approach for fetching both relay and parachain binaries.
  • Moved the parse_latest_tag method, which identifies the latest version by prioritizing stable-format tags, into a helper module. It was used to fetch templates, now is used for fetching relay and parachain binaries too.

Copy link
Contributor

@evilrobot-01 evilrobot-01 left a comment

Choose a reason for hiding this comment

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

Looks good apart from the use of 'helpers'. Its highly subjective, but my view is that using 'helpers' does nothing for discoverability of code and therefore fails in terms of devex for the crate consumer. Modules can be descriptive and expressive.

crates/pop-common/src/helpers.rs Outdated Show resolved Hide resolved
crates/pop-common/src/helpers.rs Outdated Show resolved Hide resolved
crates/pop-common/src/helpers.rs Outdated Show resolved Hide resolved
crates/pop-common/src/helpers.rs Outdated Show resolved Hide resolved
crates/pop-common/src/helpers.rs Outdated Show resolved Hide resolved
crates/pop-common/src/sourcing/binary.rs Outdated Show resolved Hide resolved
Copy link

codecov bot commented Nov 5, 2024

Codecov Report

Attention: Patch coverage is 94.73684% with 6 lines in your changes missing coverage. Please review.

Project coverage is 70.35%. Comparing base (2af82eb) to head (6a7e033).
Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
crates/pop-common/src/polkadot_sdk.rs 95.00% 0 Missing and 5 partials ⚠️
crates/pop-parachains/src/up/parachains.rs 66.66% 0 Missing and 1 partial ⚠️
@@            Coverage Diff             @@
##             main     #328      +/-   ##
==========================================
+ Coverage   70.33%   70.35%   +0.02%     
==========================================
  Files          53       54       +1     
  Lines        9098     9105       +7     
  Branches     9098     9105       +7     
==========================================
+ Hits         6399     6406       +7     
  Misses       1718     1718              
  Partials      981      981              
Files with missing lines Coverage Δ
crates/pop-common/src/git.rs 71.10% <100.00%> (-5.23%) ⬇️
crates/pop-common/src/lib.rs 61.29% <ø> (ø)
crates/pop-common/src/sourcing/binary.rs 92.30% <100.00%> (+0.02%) ⬆️
crates/pop-parachains/src/up/chain_specs.rs 83.03% <ø> (ø)
crates/pop-parachains/src/up/relay.rs 85.93% <100.00%> (+0.33%) ⬆️
crates/pop-parachains/src/up/parachains.rs 86.38% <66.66%> (+0.14%) ⬆️
crates/pop-common/src/polkadot_sdk.rs 95.00% <95.00%> (ø)

Copy link
Contributor

@al3mart al3mart left a comment

Choose a reason for hiding this comment

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

Couldn't point out anything. Nice one!

Copy link
Contributor

@evilrobot-01 evilrobot-01 left a comment

Choose a reason for hiding this comment

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

LGTM, thank you!

@AlexD10S AlexD10S merged commit c807ba0 into main Nov 7, 2024
20 checks passed
@AlexD10S AlexD10S deleted the alex/fix-fetch-stable branch November 7, 2024 14:23
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.

3 participants