Skip to content

Conversation

@AA-Turner
Copy link
Member

@hauntsaninja noted that a PR would likely be welcome, so opening here.

xref #867, #867 (comment)

A

@AA-Turner AA-Turner changed the title Clean-up typing_extensions after support dropped older Pythons Clean-up typing_extensions after support dropped for older Pythons Sep 16, 2021
@AA-Turner
Copy link
Member Author

Rebased onto latest master after #893
A

Copy link
Member

@JelleZijlstra JelleZijlstra left a comment

Choose a reason for hiding this comment

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

Thanks for all this work!

This looks good, but I'll want to check manually that 3.6.0 and 3.6.1 still work since they're not covered by CI.

CONTRIBUTING.md Outdated
Python 2.7 and 3.4. However, it is OK to omit support for Python versions that have
`typing_extensions` supports Python 3.6+. However, it is OK to omit support for Python versions that have
reached end of life if doing so is too difficult or otherwise does not make sense. For
example, `typing_extensions.AsyncGenerator` only exists on Python 3.6 and higher,
Copy link
Member

Choose a reason for hiding this comment

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

This example doesn't make sense any more because only 3.6+ are supported. Maybe we can recast it to say something like "Back when we still supported 3.5, AsyncGenerator was only available in 3.6+"

Copy link
Member Author

Choose a reason for hiding this comment

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

Updated to "For example, typing_extensions.AsyncGenerator was only supported in Python 3.6 and newer, because async generators were not part of the language before then."

A

Copy link
Member Author

Choose a reason for hiding this comment

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

You could also phrase in the negative -- e.g. "For example, typing_extensions.AsyncGenerator was not supported in Python versions before 3.6, as async generators were not part of the language."

@AA-Turner
Copy link
Member Author

3.6.0 and 3.6.1 still work

I checked 3.6.0, but not 3.6.1 -- although I think I covered all the edge cases for changes between micro versions.

A


if HAVE_PROTOCOLS:
__all__.extend(['Protocol', 'runtime', 'runtime_checkable'])
__all__.extend(['Annotated', 'Protocol', 'runtime', 'runtime_checkable'])
Copy link
Member Author

Choose a reason for hiding this comment

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

Given these names are now unconditionally added to __all__, I think they should be in the initial definition -- but not sure in which category to put them

A

@srittau
Copy link
Collaborator

srittau commented Oct 8, 2021

I'm sorry that there hasn't been any feedback lately. Part of it is that I didn't yet have time to fully review the changes in the src dir, part that I wasn't sure how to best proceed, considering our lack of a clear versioning policy. I have opened python/typing_extensions#32 to clear the latter up.

@AA-Turner
Copy link
Member Author

Thanks Sebastian

If I could do anything to ease the review, happy to help.

Also happy to wait until the versioning policy has been clarified.

A

@srittau
Copy link
Collaborator

srittau commented Nov 9, 2021

And sorry again. Could you maybe split this into two PRs: One with the changes to typing_extensions and one with the "meta" changes for the build process? I had already reviewed the meta changes and then didn't find the time to continue with the lib. Splitting it would be easier.

@AA-Turner
Copy link
Member Author

Done @srittau
A

@srittau
Copy link
Collaborator

srittau commented Nov 11, 2021

@AA-Turner: Thanks for splitting! Is this PR still relevant or can it be closed?

@AA-Turner
Copy link
Member Author

No, closing. Thanks!

@srittau srittau closed this Nov 11, 2021
@AA-Turner AA-Turner deleted the cleanup branch November 11, 2021 15:32
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.

4 participants