Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1559 +/- ##
====================================
Coverage 74% 74%
====================================
Files 36 36
Lines 3993 3996 +3
====================================
+ Hits 2976 2979 +3
Misses 1017 1017
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Contributor
There was a problem hiding this comment.
Pull request overview
Bundles both the legacy Ruby CLIs (from pact-standalone) and the newer Rust pact CLI (from pact-cli), and emits a deprecation warning when users invoke Ruby-based wrapper commands.
Changes:
- Add stderr deprecation warnings for Ruby CLI entrypoints, with an optional “use
<pact subcommand>instead” hint. - Update the Hatch build hook to download/extract Ruby standalone assets and additionally download/copy the Rust
pactbinary intobin/. - Add pytest coverage to validate which commands do/do not emit the deprecation warning.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| pact-python-cli/tests/test_init.py | Adds tests asserting deprecated wrappers warn and pact does not. |
| pact-python-cli/src/pact_cli/init.py | Replaces warnings.warn with explicit stderr warnings and introduces a replacement-command mapping. |
| pact-python-cli/hatch_build.py | Downloads Ruby standalone plus an additional Rust pact binary during wheel build. |
Until recently, the `pact-standalone` upstream CLI bundled both Ruby and Rust CLIs together. The Ruby CLIs are being deprecated and will be removed, and the `pact-cli` repository will contain the Rust-based CLI which replaces all of the Ruby ones. For now, this bundles both to preserve compatibility, and adds a deprecation warning in preparation for the upcoming removal. Signed-off-by: JP-Ellis <josh@jpellis.me>
bc49301 to
81a383f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
📝 Summary
pact-standaloneandpact-clirespectively.🚨 Breaking Changes
None yet, but deprecation warning is there for upcoming removal.
🔥 Motivation
Until recently, the
pact-standaloneupstream CLI bundled both Ruby and Rust CLIs together. The Ruby CLIs are being deprecated and will be removed, and thepact-clirepository will contain the Rust-based CLI which replaces all of the Ruby ones.🔨 Test Plan
Add some tests
🔗 Related issues/PRs