-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
[BugFix] Make User Preferences -> Defaults Work With Any Parameter #6687
Conversation
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.
@@ -37,7 +57,7 @@ def _check_credentials(self, provider: str) -> Optional[bool]: | |||
return all(getattr(credentials, r, None) for r in required) | |||
|
|||
def _get_provider( | |||
self, choice: Optional[str], command: str, default_priority: Tuple[str, ...] |
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 had the idea that this (not using typing's type hints) would break on 3.9 envs, but it didn't, probably a 3.8 thing 😀
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.
Aside from the warnings @hjoaquim mentioned, this looks good!
Warnings are coming from the |
Why?:
user_settings.json
was not able to cope with anything other than "provider".What?:
Defaults
class so that validation errors don't happen when supplying other parameters.Container
/Command
classes if they are not supplied at runtime.Impact:
Testing Done:
User Settings:
Before:
After: