- Sponsor
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Fix Literal bug with typing-extension==4.6.0 #5826
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
7f0a4d5
to
93ef367
Compare
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'm not familiar with pydantic
internals, but this looks like a reasonable fix to me!
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Sure. Thanks! |
Will this fix be delivered as Pydantic 1.10.8 immediately? If yes, I will wait and not implement any workarounds. |
989eecb
to
aab48c9
Compare
I wonder if it might not be a good idea to introduce an upper bound ( The same applies to the master branch of course. |
Honestly, I feel like this situation illustrates the inadequacies of SemVer more than anything else |
agreed.
No. There are many articles out there about why including upper bounds in package dependencies is almost always a bad idea.
We'll do our best to get it out asap. |
Although I don't feel like |
No problem @AlexWaygood, these things happen. It's the responsibility of app developers to pin dependencies. CF build failures is a random download issue, see my angry tweet. |
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.
otherwise LGTM.
if type_ is none_type: | ||
return True | ||
return False | ||
return type_ in NONE_TYPES |
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 looks weird enough that we might have done it for some strange reason, can we confirm this was just a code smell?
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.
The existing approach(checking with is
) does not work in Python 3.9
and typing-extension==4.6.0
. That's why I've changed it.
Note: the new approach is also Ok with typing-extension==4.5.0
. So, it might be a wrong implementation before
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.
thanks @hramezani.
Can we uprev the version we test with?
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.
Done!
This should be fixed now in the just-released 1.10.8, which should be available through PyPI shortly. |
Done |
Fixes #5821