-
Notifications
You must be signed in to change notification settings - Fork 321
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
Fix resetting warning filters after silencing RDT warning about refit #1619
Conversation
Codecov ReportAll modified lines are covered by tests ✅
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## main #1619 +/- ##
=======================================
Coverage 97.13% 97.13%
=======================================
Files 48 48
Lines 4192 4193 +1
=======================================
+ Hits 4072 4073 +1
Misses 120 120
☔ View full report in Codecov by Sentry. |
self._hyper_transformer.update_transformers(column_name_to_transformer) | ||
warnings.resetwarnings() | ||
with warnings.catch_warnings(): | ||
msg = rdt.HyperTransformer._REFIT_MESSAGE |
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.
One drawback of pulling the warning message from RDT directly is that if RDT renames the _REFIT_MESSAGE
attribute to some other name the code will break. If instead we harcoded msg
and the warning message changed from the RDT side, this code would fail to silence the warning but the execution would not fail.
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.
Can we just filter all warnings from the HyperTransformer
? Seems like thats what we were doing before (actually more broad since it filtered all of RDT) and that way we don't have to worry about the message
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.
LGTM!
Resolve #1618