Open frostming opened 3 years ago
Basically agree. It should be split into multiple packages, which can be collectively called stdlib.xxx.
Each patch library of the standard library corresponds to a stdlib.xxxxx, such as stdlib.datetime. The version number composition should be python minor version + number. For example, 3.10.x means that this version of the patch library corresponds to the 3.10 version of the standard library implementation.
It seems stdlib
is already taken. Agree with the version number part.
stdlib
is a empty package. And we can use like stdlib.datetime
、stdlib.importlib
If we are to use namespace packages, that will cause namespace conflict, we need to ensure all submodules stdlib.xxx
are shimmed modules, not anything else.
Why will have namespace conflict? It's just pypi package name, not module name in site-packages.
For a namespace package, the file is structure is as follows:
stdlib
importlib
__init__.py
subprocess
__init__.py
collections
__init__.py
Each child package installs a submodule into the stdlib
parent folder(If you are not going to pick another name). It is designed to enable auto-discovery, so it shouldn't contain other non-shim modules.
BTW, if you think a meeting is necessary, let's arrange one.
I agree. Then we should make a template repository for stdlib.xxx
.
Before starting implementing backports modules, we need to first decide how it should go. Here are some suggestions from my point of view, while others can comment to recommend alternatives.
The project name
last standard just doesn't look good to me. It is indeed "Latest" not "Last". We should pick another name for it as the PyPI canonical name, I am not good at it though. As it is going to be the name for multiple child packages, I don't recommend any name more than a single word. Some candidates I can think of that are not occupied:
Distribution
we will define an entry point group and each shim will register their entry points. So there should be a core package under the namespace to bootstrap all shims when Python starts up, this package must be depended on by all shims and be installed if any of the shims are installed.the core library will scan all submodules under that namespace and load them correctly.sys.modules
.Requirements for a shim