FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Python 3.15: sort allowlists, more small updates by JelleZijlstra · Pull Request #15714 · python/typeshed · GitHub

Repository navigation

Python 3.15: sort allowlists, more small updates - #15714

Merged
srittau merged 37 commits into
python:mainfrom
JelleZijlstra:python315
May 13, 2026
Merged

srittau merged 37 commits into
python:mainfrom
JelleZijlstra:python315

Conversation

JelleZijlstra commented May 8, 2026 •
edited
Loading

Copy link
Copy Markdown
Member

Part of #15709.

I pointed Codex at the What's New for 3.15 and told it to apply every change relevant to typeshed, then told it to get stubtest running on 3.15 (which found python/cpython#149504) and fix the remaining issues. I also reviewed manually and made a few adjustments (including noticing python/cpython#149534).

Most of the changes were split into smaller PRs; this one now is allowlist sorting plus a few smaller things that were missed. There's a few more allowlist entries that look fixable, but I'll save that for later PRs.

# Conflicts:
#	stdlib/_interpqueues.pyi
#	stdlib/ast.pyi
#	stdlib/base64.pyi
#	stdlib/collections/__init__.pyi
#	stdlib/glob.pyi
#	stdlib/importlib/metadata/__init__.pyi
#	stdlib/pyexpat/__init__.pyi
#	stdlib/sys/__init__.pyi
#	stdlib/threading.pyi
#	stdlib/types.pyi
#	stdlib/typing.pyi
#	stdlib/unicodedata.pyi
#	stdlib/unittest/_log.pyi
#	stdlib/unittest/case.pyi
#	stdlib/wave.pyi
#	stdlib/zipimport.pyi

This comment has been minimized.

srittau commented May 8, 2026

Copy link
Copy Markdown
Collaborator

I would like to get the testing infrastructure for 3.15 up before adding 3.15 branches. It also doesn't fill me with confidence that we already have stubtest errors without even testing 3.15.

srittau commented May 8, 2026

Copy link
Copy Markdown
Collaborator

Here's my suggestion on how to move forward:

  1. Get the testing infrastructure in place. We'll need to add many stubtest allow entries as a "to do list" to the 3.15 allow lists. (Like we had in the past.)
  2. Split this PR into multiple PRs with a size that's easily reviewable.
  3. Fix remaining issues per PR, but move "harder" fixes to separate PRs if necessary.
  4. Review each PR manually for plausibility and style. When looking at the existing PR, it's clear to me that on the one hand the LLM managed to do a lot of the "grunt work" and provide a good baseline, but on the other hand delivered results that are not suitable for unsupervised inclusion in typeshed.

sobolevn left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Thanks a lot for this work! I agree with @srittau that it is rather hard to review 1600+ lines of changes accross different modules :(

Comment thread stdlib/collections/__init__.pyi Outdated
Comment thread stdlib/sys/__init__.pyi Outdated

Copy link
Copy Markdown
Contributor

Hi! There's one new addition in 3.15 which I notice is missing from the release notes and the current PR:
python/cpython#140951
https://docs.python.org/3.15/library/wave.html#wave.open.

I guess if the What's New is up to date there shouldn't be a problem for the AI but maybe there are other changes also missing?

Copy link
Copy Markdown
Member Author

wave.open: Yes, I had it look only at the What's New. I think we're liable to miss such changes to only allowed parameter types, because there's no automatic way to check them; I wouldn't be surprised if we similarly missed some changes for earlier versions. Maybe I'll try making an AI look at the whole diff between 3.14 and 3.15 and flag things that were missed.

Point taken on getting CI set up first, I'll do that.

The stubtest failures seem to be mostly from changes that were made unconditionally that should have been made conditional on version.

JelleZijlstra marked this pull request as draft May 8, 2026 16:11

Copy link
Copy Markdown
Member Author

My plan now:

  • Add 3.15 CI (Add Python 3.15 test infrastructure #15718)
  • Make Codex fix all CI issues on this PR to have a clean slate (in progress)
  • Extract separate PRs for smaller changes (probably <5 modules at a time); start them as draft and request review when I feel they're ready.

srittau commented May 8, 2026

Copy link
Copy Markdown
Collaborator

Extract separate PRs for smaller changes (probably <5 modules at a time); start them as draft and request review when I feel they're ready.

I'll try to prioritize reviewing. If it's just small, straight-forward changes, I'm fine with larger PRs. It's more about the amount if lines and the complexity than the amount of modules.

Comment thread stdlib/profiling/sampling.pyi Outdated

This comment has been minimized.

# Conflicts:
#	stdlib/@tests/stubtest_allowlists/darwin-py315.txt
#	stdlib/@tests/stubtest_allowlists/linux-py315.txt
#	stdlib/@tests/stubtest_allowlists/py315.txt
#	stdlib/@tests/stubtest_allowlists/win32-py315.txt
#	stdlib/_collections_abc.pyi
#	stdlib/_socket.pyi
#	stdlib/_ssl.pyi
#	stdlib/binascii.pyi
#	stdlib/builtins.pyi
#	stdlib/calendar.pyi
#	stdlib/collections/__init__.pyi
#	stdlib/datetime.pyi
#	stdlib/difflib.pyi
#	stdlib/hashlib.pyi
#	stdlib/mmap.pyi
#	stdlib/platform.pyi
#	stdlib/re.pyi
#	stdlib/resource.pyi
#	stdlib/socket.pyi
#	stdlib/sqlite3/__init__.pyi
#	stdlib/typing.pyi
#	stdlib/unittest/_log.pyi
#	stdlib/wave.pyi
Comment thread stdlib/collections/__init__.pyi Outdated

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

# Conflicts:
#	stdlib/@tests/stubtest_allowlists/py315.txt

This comment has been minimized.

This comment has been minimized.

JelleZijlstra changed the title Update stdlib for Python 3.15 Python 3.15: sort allowlists, more small updates May 13, 2026

Copy link
Copy Markdown
Member Author

With lots of other PRs merged, this is now mostly allowlist sorting.

JelleZijlstra marked this pull request as ready for review May 13, 2026 03:32

Copy link
Copy Markdown
Contributor

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

srittau merged commit 4076e24 into python:main May 13, 2026
58 checks passed
JelleZijlstra deleted the python315 branch May 13, 2026 13:00
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants


Back | FazBrowse Home | New Git URL