-
Notifications
You must be signed in to change notification settings - Fork 124
[DRAFT] Make backwards compatibility slightly easier #1528
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
base: main
Are you sure you want to change the base?
Conversation
Restores the `CompletionItem.description` field and expands its type to work with either `str` or `Sequence[str | rich.Column]`. This reverts a breaking change introduced in 3.0.0 and makes it easier for users to migrate from version 2.7.0.
|
🤖 Hi @tleonhardt, I've received your request, and I'm working on it now! You can track my progress in the logs for more details. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1528 +/- ##
=======================================
Coverage 98.90% 98.90%
=======================================
Files 21 21
Lines 4933 4935 +2
=======================================
+ Hits 4879 4881 +2
Misses 54 54
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
📋 Review Summary
This pull request reverts a breaking change by renaming CompletionItem.descriptive_data back to CompletionItem.description and expanding its type hint to str | Sequence[Any] for improved backward compatibility. The changes are well-implemented, and the related documentation and tests have been updated accordingly.
🔍 General Feedback
- The code is clear, and the change effectively addresses the backward compatibility issue.
- The updates to the changelog and tests are accurate and appreciated.
Improve docstring to make it more accurate Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Revert
CompletionItem.descriptionfield to original name, but expand type fromstrtostr | Sequence[Any].I attempted to migrate a large
cmd2application from version 2.7.0 to 3.0.0rc1 and spent 10 hours on the effort and still wasn't done. The numerous backwards incompatibilities make it more difficult for users than it could be.This is one small attempt to start in the direction of reducing some of the more painful backwards incompatibilities.
This is a concept I'm not fully sold on. I'm just looking for ways to simplify the process of upgrading by reducing backwards incompatibilities.