-
Notifications
You must be signed in to change notification settings - Fork 10
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: Proper use enum in checking new version #1123
Conversation
WalkthroughThe changes involve updating message box configurations and restructuring the mock message box class for better organization. Specifically, Changes
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
🧙 Sourcery has finished reviewing your pull request! Tips
|
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.
We've reviewed this pull request using the Sourcery rules engine. If you would also like our AI-powered code review then let us know.
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.
Actionable comments posted: 0
Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (1)
- package/PartSeg/_launcher/check_version.py (1 hunks)
Additional comments not posted (5)
package/PartSeg/_launcher/check_version.py (5)
72-77
: Use ofQMessageBox.Icon.Information
is correct.The change from
QMessageBox.Information
toQMessageBox.Icon.Information
is correct and aligns with PyQt5/PySide2 conventions.
77-77
: Use ofQMessageBox.StandardButton.Ok | QMessageBox.StandardButton.Ignore
is correct.The change from
QMessageBox.Ok | QMessageBox.Ignore
toQMessageBox.StandardButton.Ok | QMessageBox.StandardButton.Ignore
is correct and aligns with PyQt5/PySide2 conventions.
81-86
: Use ofQMessageBox.StandardButton.Information
is correct.The change from
QMessageBox.Information
toQMessageBox.StandardButton.Information
is correct and aligns with PyQt5/PySide2 conventions.
86-86
: Use ofQMessageBox.StandardButton.Ignore
is correct.The change from
QMessageBox.Ignore
toQMessageBox.StandardButton.Ignore
is correct and aligns with PyQt5/PySide2 conventions.
89-89
: Correct usage ofQMessageBox.StandardButton.Ignore
in the condition.The change from
QMessageBox.Ignore
toQMessageBox.StandardButton.Ignore
in the condition is correct and aligns with PyQt5/PySide2 conventions.
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.
Actionable comments posted: 0
Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (2)
- package/PartSeg/_launcher/check_version.py (1 hunks)
- package/tests/test_PartSeg/test_check_release.py (1 hunks)
Additional comments not posted (7)
package/PartSeg/_launcher/check_version.py (5)
72-77
: Correct use ofQMessageBox.Icon.Information
.The change from
QMessageBox.Information
toQMessageBox.Icon.Information
is correct and follows the updated API.
77-77
: Correct use ofQMessageBox.StandardButton.Ok | QMessageBox.StandardButton.Ignore
.The change from
QMessageBox.Ok | QMessageBox.Ignore
toQMessageBox.StandardButton.Ok | QMessageBox.StandardButton.Ignore
is correct and follows the updated API.
81-86
: Correct use ofQMessageBox.Icon.Information
.The change from
QMessageBox.Information
toQMessageBox.Icon.Information
is correct and follows the updated API.
86-86
: Correct use ofQMessageBox.StandardButton.Ok | QMessageBox.StandardButton.Ignore
.The change from
QMessageBox.Ok | QMessageBox.Ignore
toQMessageBox.StandardButton.Ok | QMessageBox.StandardButton.Ignore
is correct and follows the updated API.
89-89
: Correct use ofQMessageBox.StandardButton.Ignore
.The change from
QMessageBox.Ignore
toQMessageBox.StandardButton.Ignore
is correct and follows the updated API.package/tests/test_PartSeg/test_check_release.py (2)
46-50
: Correct restructuring ofMockMessageBox.StandardButton
.The restructuring of
MockMessageBox
to include the nested classStandardButton
with constantsInformation
,Ok
, andIgnore
is correct and improves organization.
51-52
: Correct restructuring ofMockMessageBox.Icon
.The restructuring of
MockMessageBox
to include the nested classIcon
with the constantInformation
is correct and improves organization.
Quality Gate passedIssues Measures |
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.
Actionable comments posted: 0
Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (1)
- package/tests/test_PartSeg/test_check_release.py (2 hunks)
Files skipped from review as they are similar to previous changes (1)
- package/tests/test_PartSeg/test_check_release.py
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #1123 +/- ##
===========================================
+ Coverage 92.91% 92.93% +0.01%
===========================================
Files 205 205
Lines 32519 32519
===========================================
+ Hits 30215 30220 +5
+ Misses 2304 2299 -5 ☔ View full report in Codecov by Sentry. |
Summary by CodeRabbit
Bug Fixes
Refactor
MockMessageBox
class for better organization of constants.