-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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: allow empty string aliases with AliasGenerator
#8810
Conversation
Please review |
Deploying with
|
Latest commit: |
158a2bc
|
Status: | ✅ Deploy successful! |
Preview URL: | https://c9f31cc9.pydantic-docs2.pages.dev |
Branch Preview URL: | https://alias-gen-str-fixes.pydantic-docs2.pages.dev |
CodSpeed Performance ReportMerging #8810 will not alter performanceComparing Summary
|
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 feel free to ignore my suggestion.
@@ -296,6 +296,15 @@ def push(self, for_type: type[Any]): | |||
self._types_namespace_stack.pop() | |||
|
|||
|
|||
def _get_first_non_null(a: Any, b: Any) -> Any: |
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.
def _get_first_non_null(a: Any, b: Any) -> Any: | |
def _get_first_not_none(a: Any, b: Any) -> Any: |
not a big deal.
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.
For what it's worth, I don't think it would be crazy to just copy the if <a> is not None else
everywhere, but I'm okay with this too.
Fix #8808
Selected Reviewer: @dmontagu