-
-
Notifications
You must be signed in to change notification settings - Fork 211
Added warning to run_model_on_task to avoid duplicates if no authentication #1246
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
Added warning to run_model_on_task to avoid duplicates if no authentication
for more information, see https://pre-commit.ci
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## develop #1246 +/- ##
===========================================
- Coverage 85.24% 85.16% -0.08%
===========================================
Files 38 38
Lines 5008 5010 +2
===========================================
- Hits 4269 4267 -2
- Misses 739 743 +4
... and 5 files with indirect coverage changes Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report in Codecov by Sentry. |
PGijsbers
left a comment
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.
Thanks for your contribution! Please see my suggestion
| warnings.warn( | ||
| "avoid_duplicate_runs is set to True, but no API key is set. " | ||
| "Please set your API key in the OpenML configuration file " | ||
| "or pass it directly to the function.", | ||
| DeprecationWarning, | ||
| ) |
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.
| warnings.warn( | |
| "avoid_duplicate_runs is set to True, but no API key is set. " | |
| "Please set your API key in the OpenML configuration file " | |
| "or pass it directly to the function.", | |
| DeprecationWarning, | |
| ) | |
| warnings.warn( | |
| "avoid_duplicate_runs is set to True, but no API key is set. " | |
| "Please set your API key in the OpenML configuration file, see" | |
| "https://openml.github.io/openml-python/main/examples/20_basic/introduction_tutorial.html#authentication" | |
| " for more information on authentication.", | |
| ) |
Two changes:
- I don't think
DeprecationWarningis appropriate here because we are not informing about changed behavior/signature of the function, I would favor theUserWarning(which is the default warning type, so I left that argument implicit). - There is no way to pass the API key to the function, so that help text is incorrect. I updated the text to point to the documentation.
|
Sorry, missed the update. LGTM. Thanks for your contribution! |
Added warning to run_model_on_task to avoid duplicates if no authentication
Reference Issue
#1210