-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
Deprecate passing keys to update_keymap as single comma-separated string #17394
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
By me, it would be fine to directly deprecate towards a single signature. And that signature would naturally be ... ... Um, I was going to say a single list, because
|
Yeah, asking people to write |
Docstring and deprecation message must be updated too. |
... to ToolManager.update_keymap. This allows one to correctly set a keymap to "," (a single comma). This also will help further cleanup of rc validators (by not "leaking" validate_stringlist out of rcsetup).
done |
|
||
Passing multiple keys as a single comma-separated string or multiple arguments to `.ToolManager.update_keymap` | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
This is deprecated; pass keys as a list of strings instead. |
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.
This is deprecated; pass keys as a list of strings instead. | |
This is deprecated; pass keys as a single string or a list of strings instead. |
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.
I thought "single string" was too confusing (as it used to be a single string before too... I guess it should be "single string if you're only passing a single key", but heh) and just documenting "list of strings" here was good enough (even though we support the single string option too).
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.
Ok, since this is just the deprecation notice and not the reference docstring, the imprecision is tolerable 😄 .
... to ToolManager.update_keymap.
This allows one to correctly set a keymap to "," (a single comma). This
also will help further cleanup of rc validators (by not "leaking"
validate_stringlist out of rcsetup).
PR Summary
PR Checklist