-
Notifications
You must be signed in to change notification settings - Fork 3
Warn when max workers is not set #753
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
Conversation
WalkthroughThe function Changes
Estimated code review effort2 (10–30 minutes) Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. 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 using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
# Conflicts: # executorlib/standalone/inputcheck.py
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
🧹 Nitpick comments (1)
executorlib/standalone/inputcheck.py (1)
194-199: Addstacklevelparameter to the warning call.The warning implementation improves user experience by explicitly informing when
max_workersdefaults to CPU count. However, the static analysis tool correctly identifies that thestacklevelparameter should be set to point the warning to the caller's code.Apply this diff to address the static analysis hint:
- warn( - "max_workers parameter is not set, set default based on CPU count to: max_workers=" - + str(max_workers) - ) + warn( + "max_workers parameter is not set, set default based on CPU count to: max_workers=" + + str(max_workers), + stacklevel=2 + )
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
executorlib/standalone/inputcheck.py(2 hunks)
🧰 Additional context used
🪛 Ruff (0.12.2)
executorlib/standalone/inputcheck.py
195-195: No explicit stacklevel keyword argument found
Set stacklevel=2
(B028)
🔇 Additional comments (1)
executorlib/standalone/inputcheck.py (1)
6-6: LGTM!The import addition is necessary for the warning functionality and follows Python conventions.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #753 +/- ##
=======================================
Coverage 97.42% 97.42%
=======================================
Files 31 31
Lines 1396 1399 +3
=======================================
+ Hits 1360 1363 +3
Misses 36 36 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
for more information, see https://pre-commit.ci
Summary by CodeRabbit