Skip to content

Conversation

@Aniketsy
Copy link
Contributor

@Aniketsy Aniketsy commented Jan 4, 2026

This includes changes in 3.10 and 3.11.

@StanFromIreland
Copy link
Member

Update your branch to fix the CI.

@picnixz
Copy link
Member

picnixz commented Jan 4, 2026

There are wrong changes. Zip is a built-in for instance. The ast module is a core module IIRC.

Copy link
Member

@picnixz picnixz left a comment

Choose a reason for hiding this comment

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

Core and Builtins also include built-in types (e.g., zip, int, map, etc), and their methods. I won't go through all occurrences, but please correct them.

.. date: 2021-05-04-21-55-49
.. nonce: M9m8Qd
.. section: Core and Builtins
.. section: Library
Copy link
Member

Choose a reason for hiding this comment

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

This must stay as a core and builtins. It's about getattr/hasattr which are builtins.

This comment was marked as spam.

@bedevere-app
Copy link

bedevere-app bot commented Jan 4, 2026

A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated.

Once you have made the requested changes, please leave a comment on this pull request containing the phrase I have made the requested changes; please review again. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.

@Aniketsy
Copy link
Contributor Author

Aniketsy commented Jan 4, 2026

Thanks, I’ll revisit these and also correct them in the previous PR

.. section: Core and Builtins
.. section: Library
Add ``sys._current_exceptions()`` function to retrieve a dictionary mapping
Copy link
Member

Choose a reason for hiding this comment

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

sysmodule is a core & built-in strictly speaking, but I think it's fine to keep it under Library as it's the user-facing stuff.

This comment was marked as spam.

.. date: 2021-01-13-14-06-01
.. nonce: _WS1Ok
.. section: Core and Builtins
.. section: Library
Copy link
Member

Choose a reason for hiding this comment

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

bytearray is a built-in...

.. date: 2018-12-20-23-59-23
.. nonce: idHEcj
.. section: Core and Builtins
.. section: Library
Copy link
Member

Choose a reason for hiding this comment

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

This is affecting string formattin... so built-in.

.. section: Core and Builtins
.. section: Library
The import system now prefers using ``__spec__`` for ``ModuleType.__repr__``
Copy link
Member

@picnixz picnixz Jan 4, 2026

Choose a reason for hiding this comment

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

This is a core... it's part of the import system. Everything related to imports is part of the core.

.. date: 2021-03-16-17-12-54
.. nonce: zAo6Ws
.. section: Core and Builtins
.. section: Library
Copy link
Member

Choose a reason for hiding this comment

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

Again.

.. date: 2021-09-02-01-28-01
.. nonce: QDjM_l
.. section: Core and Builtins
.. section: Library
Copy link
Member

Choose a reason for hiding this comment

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

I'd say both Library and Core and Builtins. I'd prefer Core and Builtins because of open.

.. date: 2022-01-25-19-34-55
.. nonce: mQLNPk
.. section: Core and Builtins
.. section: Library
Copy link
Member

Choose a reason for hiding this comment

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

Builtin.

@Aniketsy
Copy link
Contributor Author

Aniketsy commented Jan 4, 2026

I’d like to apologize for increasing the review workload.

.. date: 2020-10-10-14-16-03
.. nonce: Xop8sV
.. section: Core and Builtins
.. section: Library
Copy link
Member

Choose a reason for hiding this comment

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

This is still a core & builtins.

.. section: Core and Builtins
.. section: Library
Raise ImportWarning when calling find_loader().
Copy link
Member

Choose a reason for hiding this comment

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

Is this change affecting more only importlib or is it affecting the entire interpreter?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This change only affects importlib

Copy link
Contributor

Choose a reason for hiding this comment

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

I'm thinking this one is Core and Builtins. It's true that the changes are in importlib, but the PR modifies _bootstrap_external.py and thus affects how cpython finds modules globally. Specifically, I expect anything that uses find_loader() would be implicated by this change.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for pointing this out.

.. date: 2021-12-11-11-36-48
.. nonce: sfThay
.. section: Core and Builtins
.. section: Library
Copy link
Member

Choose a reason for hiding this comment

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

This one is also a build. I said on the issue that one should be careful about possible duplicated NEWS entries because of backports.

@python python deleted a comment from Bjorka13 Jan 6, 2026
@picnixz
Copy link
Member

picnixz commented Jan 6, 2026

@python/organization-owners Please block @Bjorka13 for spam review. TiA.

Comment on lines +92 to 94
.. section: Library

Port the ``_warnings`` extension module to the multi-phase initialization
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Since this change is in Python/_warnings.c, should this entry stay under Core and Builtins?

Copy link
Member

Choose a reason for hiding this comment

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

It's in Python because we need to access it from everywhere, but the module itself is more as a "library" module. @serhiy-storchaka thoughts on this one? I think it doesn't really matter though (and it could even be a "build" change...).

Copy link
Member

Choose a reason for hiding this comment

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

This is on border. I have no strong opinion.

There is a stable C API for warnings, but it can be used without importing the module, and I think this change did not affect the users of this C API. So, I think it is fine to keep Library.

@@ -102,7 +102,7 @@ blocks
.. bpo: 42639
.. date: 2020-12-09-01-55-10
.. nonce: 5pI5HG
.. section: Core and Builtins
.. section: Library

Make the :mod:`atexit` module state per-interpreter. It is now safe have
more than one :mod:`atexit` module instance. Patch by Donghee Na and Victor
Copy link
Contributor Author

Choose a reason for hiding this comment

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

As per PR description (Core and Builtins)

Copy link
Member

Choose a reason for hiding this comment

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

There is a distinction between a built-in module and a built-in. I'd leave it in "Library" here. (A builtin module is a module that is always in the interpreter and contributes to its overall filesize; it's also statically linked). What matters here is what happens for the user (that is, they can now use atexit in sub-interpreters).

Copy link
Member

Choose a reason for hiding this comment

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

There is no stable public C API for atexit. Even if this is tied to interpreter internals, the only way it can be used by importing the atexit module. So, Library.

@@ -91,7 +91,7 @@ Galindo.
.. bpo: 42134
.. date: 2021-03-26-17-30-19
.. nonce: G4Sjxg
.. section: Core and Builtins
.. section: Library

Calls to find_module() by the import system now raise ImportWarning.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Since the changes are in Lib/importlib/_bootstrap.py and Lib/importlib/_bootstrap_external.py, I believe this belongs in Core and Builtins. @picnixz could you please confirm?

Copy link
Member

Choose a reason for hiding this comment

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

Yes.

@@ -917,7 +917,7 @@ Add ``__parameters__`` attribute and ``__getitem__`` operator to
.. bpo: 44523
.. date: 2021-06-29-11-49-29
.. nonce: 67-ZIP
.. section: Core and Builtins
.. section: Library

Remove the pass-through for :func:`hash` of :class:`weakref.proxy` objects
to prevent unintended consequences when the original referred object dies
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Changes are in Objects/weakrefobject.c (Core and Builtins)

Copy link
Member

Choose a reason for hiding this comment

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

Well.. for the end-user weakrefs are somehow between a built-in and not a built-in depending on the usage, but their implementation is really tied to the interpreter. I would still keep it in Library though because it's about weakref.proxy rather than the implementation detail thereof. @serhiy-storchaka your thoughts on this change?

Copy link
Member

Choose a reason for hiding this comment

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

There is a C API for weakref.proxy, it is always present. I think it is closer to core.

@serhiy-storchaka serhiy-storchaka self-requested a review January 9, 2026 09:33
Copy link
Member

@serhiy-storchaka serhiy-storchaka left a comment

Choose a reason for hiding this comment

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

Thank you for your PR @Aniketsy, great work. Mostly LGTM, I only left few minor comments.

@@ -643,7 +643,7 @@ Convert :mod:`!_bz2` to use :c:func:`PyType_FromSpec`.
.. bpo: 41006
.. date: 2020-06-18-00-07-09
.. nonce: H-wN-d
.. section: Core and Builtins
.. section: Library
Copy link
Member

Choose a reason for hiding this comment

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

I would leave this as Core and Builtins. It is about the behavior of the core interpreter.

Comment on lines +92 to 94
.. section: Library

Port the ``_warnings`` extension module to the multi-phase initialization
Copy link
Member

Choose a reason for hiding this comment

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

This is on border. I have no strong opinion.

There is a stable C API for warnings, but it can be used without importing the module, and I think this change did not affect the users of this C API. So, I think it is fine to keep Library.

@@ -917,7 +917,7 @@ Add ``__parameters__`` attribute and ``__getitem__`` operator to
.. bpo: 44523
.. date: 2021-06-29-11-49-29
.. nonce: 67-ZIP
.. section: Core and Builtins
.. section: Library

Remove the pass-through for :func:`hash` of :class:`weakref.proxy` objects
to prevent unintended consequences when the original referred object dies
Copy link
Member

Choose a reason for hiding this comment

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

There is a C API for weakref.proxy, it is always present. I think it is closer to core.

@@ -434,7 +434,7 @@ cache when applicable.
.. bpo: 46962
.. date: 2022-03-08-21-59-57
.. nonce: UomDfz
.. section: Core and Builtins
.. section: Library
Copy link
Member

Choose a reason for hiding this comment

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

types.GenericAlias and types.UnionType are builtins. It is okay to keep Core and Builtins.

Or you can split the entry on two. There was already other entry for documentation changes. https://github.com/python/cpython/pull/31769/changes

@@ -519,7 +519,7 @@ less or equal than the starting position of non-encodable characters.
.. bpo: 34093
.. date: 2018-07-14-16-58-00
.. nonce: WaVD-f
.. section: Core and Builtins
.. section: Library
Copy link
Member

Choose a reason for hiding this comment

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

Marshalling is the part of the core.

And the purpose of this change to make .pyc files more stable.

@@ -102,7 +102,7 @@ blocks
.. bpo: 42639
.. date: 2020-12-09-01-55-10
.. nonce: 5pI5HG
.. section: Core and Builtins
.. section: Library

Make the :mod:`atexit` module state per-interpreter. It is now safe have
more than one :mod:`atexit` module instance. Patch by Donghee Na and Victor
Copy link
Member

Choose a reason for hiding this comment

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

There is no stable public C API for atexit. Even if this is tied to interpreter internals, the only way it can be used by importing the atexit module. So, Library.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaiting changes docs Documentation in the Doc dir skip news

Projects

Status: Todo

Development

Successfully merging this pull request may close these issues.

6 participants