-
-
Notifications
You must be signed in to change notification settings - Fork 26.4k
FIX allow set_{method}_request methods to be unbound #28651
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
OmarManzoor
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.
LGTM. Thanks @adrinjalali
|
Hi @adrinjalali, I was the user posting the original issue in import sklearn
from sklearn.base import BaseEstimator
from beartype import beartype
sklearn.set_config(enable_metadata_routing=True)
@beartype
class A(BaseEstimator):
def fit(self, X, y, sample_weight=None):
return self
a = A().set_fit_request(sample_weight=True) # <-- error |
|
I cannot reproduce on this branch @tvdboom , this seems to fix the issue. |
|
you are right, I messed up the install. Thanks for the fix!:D |
|
Thanks so much for resolving this so rapidly, @adrinjalali. You're amazingly responsive. I'm blown away and inspired to behave like you. Since I implicitly trust @tvdboom with @beartype's life, let's assume that this now works perfectly. Thanks again, everybody! I have learned that I should use |
thomasjpfan
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.
LGTM
Fixes #28632
Similar to what we did for
available_if, we let these methods to be unbound.@leycec could you confirm this works for you?