Apply suggestions from code review
Co-authored-by: Henry Schreiner <HenrySchreinerIII@gmail.com>
This commit is contained in:
co-authored by
Henry Schreiner
parent
901f07b586
commit
cd808df0e9
+10
-7
@@ -417,24 +417,27 @@ Default: reads your package's Python compatibility from `pyproject.toml`
|
|||||||
the package is compatible with all versions of Python that it can build.
|
the package is compatible with all versions of Python that it can build.
|
||||||
|
|
||||||
!!! note
|
!!! note
|
||||||
Rather than using this option, it's recommended you set this value
|
Rather than using this environment variable, it's recommended you set this value
|
||||||
statically in a way that your build backend can use it, too. This ensures
|
statically in a way that your build backend can use it, too. This ensures
|
||||||
that your package's metadata is correct when published on PyPI.
|
that your package's metadata is correct when published on PyPI. This
|
||||||
|
cibuildwheel-specific option is provided as an override, and therefore is only
|
||||||
|
available in environment variable form.
|
||||||
|
|
||||||
- If you have a `pyproject.toml` containing a `[project]` table, you can
|
- If you have a `pyproject.toml` containing a `[project]` table, you can
|
||||||
specify `requires-python` there.
|
specify `requires-python` there.
|
||||||
|
|
||||||
```toml
|
```toml
|
||||||
[project]
|
[project]
|
||||||
|
...
|
||||||
requires-python = ">=3.6"
|
requires-python = ">=3.6"
|
||||||
```
|
```
|
||||||
|
|
||||||
Note that build backend support for the `[project]` table is still patchy, and
|
Note that not all build backends fully support using a `[project]` table yet;
|
||||||
adding `[project]` to `pyproject.toml` can change the behaviour of your build
|
specifically setuptools just added experimental support in version 61.
|
||||||
(e.g. setuptools may ignore `install_requires` specified via `setup.py` or
|
Adding `[project]` to `pyproject.toml` requires all the other supported
|
||||||
`setup.cfg`). Make sure to double-check the build after adding.
|
values to be specified there, or to be listed in `dynamic`.
|
||||||
|
|
||||||
- If you're using setuptools, [you can set this value in `setup.cfg` or `setup.py`](https://setuptools.pypa.io/en/latest/userguide/dependency_management.html#python-requirement)
|
- If you're using setuptools, [you can set this value in `setup.cfg` (preferred) or `setup.py`](https://setuptools.pypa.io/en/latest/userguide/dependency_management.html#python-requirement)
|
||||||
and cibuildwheel will read it from there.
|
and cibuildwheel will read it from there.
|
||||||
|
|
||||||
#### Examples
|
#### Examples
|
||||||
|
|||||||
Reference in New Issue
Block a user