Skip to content

Conversation

@chungquantin
Copy link
Contributor

  • Add a new type SemanticVersion to represent to the semantic version (minor, major, patch)
  • Add a new method which_version that returns the path to the binary if the version matches the targeted one.

@chungquantin chungquantin added the ready-for-final-review The PR is ready for final review label Apr 7, 2025
@chungquantin chungquantin self-assigned this Apr 7, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

Comments suppressed due to low confidence (1)

crates/pop-cli/src/common/binary.rs:178

  • [nitpick] The test 'semantic_version_invalid_works' uses non-version strings ('bash', 'which') to test version parsing, which might not effectively validate the SemanticVersion conversion logic. Consider using controlled version strings to ensure the test accurately reflects expected behavior.
fn semantic_version_invalid_works() {

@codecov
Copy link

codecov bot commented Apr 7, 2025

Codecov Report

Attention: Patch coverage is 84.37500% with 15 lines in your changes missing coverage. Please review.

Project coverage is 78.93%. Comparing base (0de418b) to head (817127b).
Report is 4 commits behind head on main.

Files with missing lines Patch % Lines
crates/pop-cli/src/common/bench.rs 58.33% 1 Missing and 4 partials ⚠️
crates/pop-cli/src/common/binary.rs 93.05% 1 Missing and 4 partials ⚠️
crates/pop-cli/src/common/try_runtime.rs 58.33% 1 Missing and 4 partials ⚠️
@@            Coverage Diff             @@
##             main     #516      +/-   ##
==========================================
+ Coverage   78.36%   78.93%   +0.56%     
==========================================
  Files          95       98       +3     
  Lines       22339    22863     +524     
  Branches    22339    22863     +524     
==========================================
+ Hits        17507    18046     +539     
+ Misses       2680     2659      -21     
- Partials     2152     2158       +6     
Files with missing lines Coverage Δ
crates/pop-cli/src/common/bench.rs 83.64% <58.33%> (+0.09%) ⬆️
crates/pop-cli/src/common/binary.rs 78.21% <93.05%> (+9.98%) ⬆️
crates/pop-cli/src/common/try_runtime.rs 92.03% <58.33%> (-0.06%) ⬇️

... and 20 files with indirect coverage changes

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

Copy link
Collaborator

@AlexD10S AlexD10S left a comment

Choose a reason for hiding this comment

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

I test it with:

cargo install --git https://github.com/paritytech/try-runtime-cli --tag v0.7.0 --locked

And then running pop test on-runtime-upgrade it sources the lastest version:

◇  ✅ try-runtime successfully sourced. Cached at: /Users/alexbean/Library/Caches/pop/try-runtime-cli-v0.8.0

@chungquantin chungquantin merged commit 6862c4a into main Apr 7, 2025
24 of 25 checks passed
@chungquantin chungquantin deleted the chungquantin/chore-which_version branch April 7, 2025 13:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-for-final-review The PR is ready for final review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants