Commit Graph

12 Commits (05e01efa8534d19956133e19e9e84aad720abb0d)

Author SHA1 Message Date
Matt Clay a87ccd74a1
[stable-2.17] release.py - Include pyproject.toml in git add (#83892) (#83897)
(cherry picked from commit e3ccdaaa2e)
2 months ago
Matt Clay 142e46ce6b
[stable-2.17] release.py - Add missing setuptools arg to prepare (#83887) (#83888)
* release.py - Add missing setuptools arg to prepare

This allows the prepare command to accept the `--no-setuptools` argument.

It also fixes a traceback when using the `prepare` command.

* Use a more accurate type hint
(cherry picked from commit b544ac13ec)
3 months ago
Matt Clay 68b4e139a1
[stable-2.17] release.py - Auto-update setuptools upper bound (#83713) (#83742)
When releases are prepared, the upper bound on setuptools in pyproject.toml will be automatically updated
to the latest version available on PyPI. This version will then be tested by the package-data sanity test
during the release process and will be used to build the release.

This change ensures that a released version of ansible-core can be built in the future if a new setuptools
release includes breaking changes that would prevent building a functional package. If a downstream package
maintainer requires a newer setuptools version than the upper bound permits, they can patch pyproject.toml
as needed. Since ansible-core releases support specific Python versions, lack of support for new setuptools
releases will have no effect on support for future Python versions.
(cherry picked from commit 4e69d83fac)
3 months ago
Matt Clay 9f9238373e
[stable-2.17] Quality-of-life improvements for release tool (#83551) (#83558)
* Quality-of-life improvements for release tool

- Default devel releases to b1
- Default non-devel releases to rc1
- Default to release announcement to console
- Avoid auto-links in GH release annoucements for file sizes

(cherry picked from commit 20a815b03f)
5 months ago
Matt Clay 4448404b03
[stable-2.17] Update sdist path in release tool (#83058)
The latest setuptools package uses a normalized package name for the sdist.

(cherry picked from commit 8bc0d809a6)
8 months ago
Abhijeet Kasurde 1cc5efa77b
tarfile: Handle deprecation warning for extract and extractall (#81545)
* Python 3.11.4 introduces a new parameter 'filter' in extract and
extractall in tarfile. Handle deprecation warning message emitted
in Python 3.12.
* added probing mechanism in ansible-galaxy code to detect broken
data filter implementation in tarfile.

Fixes: #80832

Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
Co-authored-by: Matt Clay <matt@mystile.com>
1 year ago
Matt Clay 9afaf2216b
Remove obsolete text from release.py PR template (#81526) 1 year ago
Matt Clay 47ab59753c
Clean up release script (#81488)
* Enable mypy for the entire packaging directory

* Return CompletedProcess only when capturing output

This allows stdout/stderr on CompletedProcess to be `str` instead of `str | None`.
The unused args on CompletedProcess have been removed.
Overload type hints have been added to reflect these changes.

* Relax return type on ensure_venv

This improves consistency with its usage, since `run` accepts `env` of `dict[str, t.Any]`.
Also removed unnecssary `str()` usage when updating `env`.

* Fix type hint on suppress_when

* Fix callable annotation

* Add type hint for command_parser

PyCharm complains about using a protected member, and also that it can't find the type in the type stubs.
However, mypy properly recognizes the type.

* Avoid unnecessary TypeVar usage
1 year ago
Matt Clay 85d3305889
Fix f-string whitespace in release script (#81477) 1 year ago
Matt Clay 691c8e8603
Omit pre-built man pages from sdist (#81395)
Since man pages aren't accessible to users after a `pip install`, there's no need to include them in the sdist.
This change makes it trivial to build man pages from source, which makes them much easier to iterate on.
It also simplifies creation and testing of the sdist, since it no longer requires building man pages.

The new `packaging/cli-doc/build.py` script can generate both man pages and RST documentation.
This supports inclusion on the docs site without a dependency on `ansible-core` internals.
Having a single implementation for both simplifies keeping the two formats in sync.
1 year ago
Matt Clay d37678c5ff
Release tool improvements (#80641)
* Provide reproducible sdist builds.
* Use reproducible wheel builds.
* Add PyPI artifact checks.
2 years ago
Matt Clay a6bfa82bd0
New upstream release tool (#80179) 2 years ago