Skip to content

Commit c487789

Browse files
authored
Merge pull request #501 from mrgah/add-py-versions
Enh: added first language for Python versions
2 parents 4c220b1 + 4347b76 commit c487789

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tutorials/pyproject-toml.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -306,6 +306,14 @@ The `requires-python` field helps pip identify which Python versions that your p
306306
It is set to a single value.
307307
The [packaging specification](https://packaging.python.org/en/latest/specifications/core-metadata/#core-metadata-requires-python) defines`requires-python` as a string that uses version specifiers. Most projects will specify the oldest Python version supported by the package. In some advanced cases, an upper bound is set to indicate which future Python versions, if any, will be supported.
308308

309+
:::{admonition} But how do I figure out which Python versions I should support?
310+
:class: tip
311+
Good question. The Python developer guide provides a [status page](https://devguide.python.org/versions/) (and a handy visualization) that explains the status of each Python release. Python releases go through several different phases that are explained in [PEP 602](https://peps.python.org/pep-0602/).
312+
313+
We recommend that you use the latest Python release in the **bugfix** phase. If your Python release is in the **security** phase, we recommend migrating to a newer version of Python.
314+
315+
[SPEC 0](https://scientific-python.org/specs/spec-0000/) of the Scientific Python project suggests a common schedule for dependencies, including Python release versions, and is also worth considering for your project.
316+
:::
309317

310318
{emphasize-lines="22"}
311319
```toml

0 commit comments

Comments
 (0)