8000 ✏️ Invert order of `typing` <-> `typing_extensions` by Kludex · Pull Request #6359 · pydantic/pydantic · GitHub
[go: up one dir, main page]

Skip to content

✏️ Invert order of typing <-> typing_extensions #6359

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

Closed
wants to merge 2 commits into from

Conversation

Kludex
Copy link
Member
@Kludex Kludex commented Jul 2, 2023

The description of the error message is not accurate.

Selected Reviewer: @adriangb

@Kludex
Copy link
Member Author
Kludex commented Jul 2, 2023

please review

@cloudflare-workers-and-pages
Copy link
cloudflare-workers-and-pages bot commented Jul 2, 2023

Deploying with  Cloudflare Pages  Cloudflare Pages

Latest commit: 3e60c77
Status: ✅  Deploy successful!
Preview URL: https://8ae9ac45.pydantic-docs2.pages.dev
Branch Preview URL: https://fix-docs-error.pydantic-docs2.pages.dev

View logs

@@ -290,8 +290,7 @@ except PydanticUserError as exc_info:

## `TypedDict` version {#typed-dict-version}

This error is raised when you use `typing_extensions.TypedDict`
instead of `typing.TypedDict` on Python < 3.11.
This error is raised when you use `typing.TypedDict` instead of `typing_extensions.TypedDict` on Python < 3.12.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't it be Python < 3.11?

There is a note in docstring of the method that says we only support typing.TypedDict on Python >= 3.11.

But in the error message of the same function, we have 3.12

I think we need to change the docstring or error message

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The docstring is wrong.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will you fix it in this commit?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, it looks like it's supposed to be < 3.11 instead of < 3.12.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It needs to be 3.12 for TypedDic

@Kludex
Copy link
Member Author
Kludex commented Jul 2, 2023

please review

@adriangb
Copy link
Member
adriangb commented Jul 2, 2023

Superseded by #6370

@adriangb adriangb closed this Jul 2, 2023
@Kludex Kludex deleted the fix/docs-error branch July 8, 2023 08:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0