GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Support my PEP 649 branch by JelleZijlstra · Pull Request #412 · python/typing_extensions

Conversation

@JelleZijlstra

@JelleZijlstra JelleZijlstra commented May 25, 2024

Copy link
Copy Markdown
Member

Tests now pass with python/cpython#119361.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@JelleZijlstra
Support my PEP 649 branch
a604da5
@JelleZijlstra JelleZijlstra mentioned this pull request May 25, 2024
Implement PEP 649 and PEP 749 python/cpython#119180
Closed
21 of 30 tasks
srittau
srittau reviewed May 25, 2024
View reviewed changes
Comment thread src/test_typing_extensions.py Outdated
try:
__annotations__[1] = 2
except NameError:
pass # 3.14+

@srittau srittau May 25, 2024

Copy link
Copy Markdown
Collaborator

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.

Maybe add an assert system.version >= (3, 14) inside the except block?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

JelleZijlstra reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
@JelleZijlstra
Add asserts
45c31ed
srittau
srittau approved these changes May 25, 2024
View reviewed changes
AlexWaygood
AlexWaygood approved these changes May 26, 2024
View reviewed changes
Comment thread src/typing_extensions.py
Comment on lines +945 to +951
if "__annotations__" in ns:
own_annotations = ns["__annotations__"]
elif "__annotate__" in ns:
# TODO: Use inspect.VALUE here, and make the annotations lazily evaluated
own_annotations = ns["__annotate__"](1)
else:
own_annotations = {}

@AlexWaygood AlexWaygood May 26, 2024

Copy link
Copy Markdown
Member

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.

You mentioned in python/cpython#119361 (comment) that you'd be adding a helper function for this kind of thing at some point -- would it be worth waiting for that, since the first 3.14 alpha is some way off?

I can also see the advantages of getting typing_extensions working with your branch, though, so that you can start testing with the rest of the ecosystem that depends on typing_extensions. So I definitely don't want to block you merging this.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@JelleZijlstra JelleZijlstra May 27, 2024

Copy link
Copy Markdown
Member Author

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 do expect we'll need more changes later, but it's helpful to get this merged so I can test the rest of the ecosystem too.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

AlexWaygood reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
@JelleZijlstra
JelleZijlstra merged commit 920d60d into python:main May 27, 2024
@JelleZijlstra
JelleZijlstra deleted the pep649 branch May 27, 2024 23:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@srittau srittau srittau approved these changes
@AlexWaygood AlexWaygood AlexWaygood approved these changes

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@JelleZijlstra @srittau @AlexWaygood
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.