-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
BUG: fix tab completion #37173
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
BUG: fix tab completion #37173
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -489,6 +489,21 @@ def group_selection_context(groupby: "BaseGroupBy") -> Iterator["BaseGroupBy"]: | |
class BaseGroupBy(PandasObject, SelectionMixin, Generic[FrameOrSeries]): | ||
_group_selection: Optional[IndexLabel] = None | ||
_apply_allowlist: FrozenSet[str] = frozenset() | ||
_hidden_attrs = PandasObject._hidden_attrs | { | ||
"as_index", | ||
"axis", | ||
"dropna", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Do we want these to be hidden? Okay with keeping the same behavior as master in this PR, but maybe an issue should be opened. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Good question. From a user perspective, I think it's ok to hide them (helps users focus on groupby methods), but I also think there are situation where we want them to be visible (when developing, advanced use cases). Maybe store them as not-hidden internal attributes ( |
||
"exclusions", | ||
"grouper", | ||
"group_keys", | ||
"keys", | ||
"level", | ||
jreback marked this conversation as resolved.
Show resolved
Hide resolved
|
||
"mutated", | ||
"obj", | ||
"observed", | ||
"sort", | ||
"squeeze", | ||
} | ||
|
||
def __init__( | ||
self, | ||
|
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.
yeah can you differentiate between deprecations that we are hiding and attributes that we are hing for another reason (e.g. these are private)
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.
There may be deprecated attributes, that should not be hidden and vica versa. Also the deprecation log is in #30228, if we want to list deprecated attributes.
IMO it's ok to keep the concepts of hidden and deprecated attributes seperate.