8000 Merge pull request #11377 from pytest-dev/release-7.4.1 · pytest-dev/pytest@82eb86f · GitHub
[go: up one dir, main page]

Skip to content

Commit 82eb86f

Browse files
authored
Merge pull request #11377 from pytest-dev/release-7.4.1
Prepare release 7.4.1
2 parents fbcfd3a + 0319a0d commit 82eb86f

File tree

14 files changed

+108
-55
lines changed

14 files changed

+108
-55
lines changed

.github/workflows/deploy.yml

Lines changed: 24 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,59 @@
11
name: deploy
22

33
on:
4-
push:
5-
tags:
6-
# These tags are protected, see:
7-
# https://github.com/pytest-dev/pytest/settings/tag_protection
8-
- "[0-9]+.[0-9]+.[0-9]+"
9-
- "[0-9]+.[0-9]+.[0-9]+rc[0-9]+"
4+
workflow_dispatch:
5+
inputs:
6+
version:
7+
description: 'Release version'
8+
required: true
9+
default: '1.2.3'
1010

1111

1212
# Set permissions at the job level.
1313
permissions: {}
1414

1515
jobs:
16-
build:
16+
package:
1717
runs-on: ubuntu-latest
18+
env:
19+
SETUPTOOLS_SCM_PRETEND_VERSION: ${{ github.event.inputs.version }}
1820
timeout-minutes: 10
21+
1922
steps:
2023
- uses: actions/checkout@v3
2124
with:
2225
fetch-depth: 0
2326
persist-credentials: false
27+
2428
- name: Build and Check Package
2529
uses: hynek/build-and-inspect-python-package@v1.5
2630

2731
deploy:
2832
if: github.repository == 'pytest-dev/pytest'
29-
needs: [build]
33+
needs: [package]
3034
runs-on: ubuntu-latest
35+
environment: deploy
3136
timeout-minutes: 30
3237
permissions:
3338
id-token: write
3439
steps:
40+
- uses: actions/checkout@v3
3541
- name: Download Package
3642
uses: actions/download-artifact@v3
3743
with:
3844
name: Packages
3945
path: dist
46+
4047
- name: Publish package to PyPI
4148
uses: pypa/gh-action-pypi-publish@v1.8.5
4249

50+
- name: Push tag
51+
run: |
52+
git config user.name "pytest bot"
53+
git config user.email "pytestbot@gmail.com"
54+
git tag --annotate --message=v${{ github.event.inputs.version }} v${{ github.event.inputs.version }} ${{ github.sha }}
55+
git push origin v${{ github.event.inputs.version }}
56+
4357
release-notes:
4458

4559
# todo: generate the content in the build job
@@ -55,11 +69,11 @@ jobs:
5569
with:
5670
fetch-depth: 0
5771
persist-credentials: false
72+
5873
- name: Set up Python
5974
uses: actions/setup-python@v4
6075
with:
61-
python-version: "3.7"
62-
76+
python-version: "3.10"
6377

6478
- name: Install tox
6579
run: |

.github/workflows/test.yml

Lines changed: 22 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,19 @@ concurrency:
2727
permissions: {}
2828

2929
jobs:
30+
package:
31+
runs-on: ubuntu-latest
32+
steps:
33+
- uses: actions/checkout@v3
34+
with:
35+
fetch-depth: 0
36+
persist-credentials: false
37+
- name: Build and Check Package
38+
uses: hynek/build-and-inspect-python-package@v1.5
39+
3040
build:
41+
needs: [package]
42+
3143
runs-on: ${{ matrix.os }}
3244
timeout-minutes: 45
3345
permissions:
@@ -60,7 +72,6 @@ jobs:
6072
"macos-py310",
6173
"macos-py312",
6274

63-
"docs",
6475
"doctesting",
6576
"plugins",
6677
]
@@ -159,10 +170,6 @@ jobs:
159170
os: ubuntu-latest
160171
tox_env: "plugins"
161172

162-
- name: "docs"
163-
python: "3.7"
164-
os: ubuntu-latest
165-
tox_env: "docs"
166173
- name: "doctesting"
167174
python: "3.7"
168175
os: ubuntu-latest
@@ -175,6 +182,12 @@ jobs:
175182
fetch-depth: 0
176183
persist-credentials: false
177184

185+
- name: Download Package
186+
uses: actions/download-artifact@v3
187+
with:
188+
name: Packages
189+
path: dist
190+
178191
- name: Set up Python ${{ matrix.python }}
179192
uses: actions/setup-python@v4
180193
with:
@@ -188,11 +201,13 @@ jobs:
188201
189202
- name: Test without coverage
190203
if: "! matrix.use_coverage"
191-
run: "tox -e ${{ matrix.tox_env }}"
204+
shell: bash
205+
run: tox run -e ${{ matrix.tox_env }} --installpkg `find dist/*.tar.gz`
192206

193207
- name: Test with coverage
194208
if: "matrix.use_coverage"
195-
run: "tox -e ${{ matrix.tox_env }}-coverage"
209+
shell: bash
210+
run: tox run -e ${{ matrix.tox_env }}-coverage --installpkg `find dist/*.tar.gz`
196211

197212
- name: Generate coverage report
198213
if: "matrix.use_coverage"
@@ -206,10 +221,3 @@ jobs:
206221
fail_ci_if_error: true
207222
files: ./coverage.xml
208223
verbose: true
209-
210-
check-package:
211-
runs-on: ubuntu-latest
212-
steps:
213-
- uses: actions/checkout@v3
214-
- name: Build and Check Package
215-
uses: hynek/build-and-inspect-python-package@v1.5

RELEASING.rst

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -133,14 +133,11 @@ Releasing
133133

134134
Both automatic and manual processes described above follow the same steps from this point onward.
135135

136-
#. After all tests pass and the PR has been approved, tag the release commit
137-
in the ``release-MAJOR.MINOR.PATCH`` branch and push it. This will publish to PyPI::
136+
#. After all tests pass and the PR has been approved, trigger the ``deploy`` job
137+
in https://github.com/pytest-dev/pytest/actions/workflows/deploy.yml.
138138

139-
git fetch upstream
140-
git tag MAJOR.MINOR.PATCH upstream/release-MAJOR.MINOR.PATCH
141-
git push upstream MAJOR.MINOR.PATCH
142-
143-
Wait for the deploy to complete, then make sure it is `available on PyPI <https://pypi.org/project/pytest>`_.
139+
This job will require approval from ``pytest-dev/core``, after which it will publish to PyPI
140+
and tag the repository.
144141

145142
#. Merge the PR. **Make sure it's not squash-merged**, so that the tagged commit ends up in the main branch.
146143

changelog/10337.bugfix.rst

Lines changed: 0 additions & 2 deletions
This file was deleted.

changelog/10702.bugfix.rst

Lines changed: 0 additions & 1 deletion
This file was deleted.

changelog/10811.bugfix.rst

Lines changed: 0 additions & 2 deletions
This file was deleted.

doc/en/announce/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ Release announcements
66
:maxdepth: 2
77

88

9+
release-7.4.1
910
release-7.4.0
1011
release-7.3.2
1112
release-7.3.1

doc/en/announce/release-7.4.1.rst

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
pytest-7.4.1
2+
=======================================
3+
4+
pytest 7.4.1 has just been released to PyPI.
5+
6+
This is a bug-fix release, being a drop-in replacement. To upgrade::
7+
8+
pip install --upgrade pytest
9+
10+
The full changelog is available at https://docs.pytest.org/en/stable/changelog.html.
11+
12+
Thanks to all of the contributors to this release:
13+
14+
* Bruno Oliveira
15+
* Florian Bruhin
16+
* Ran Benita
17+
18+
19+
Happy testing,
20+
The pytest Development Team

doc/en/builtin.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ For information about fixtures, see :ref:`fixtures`. To see a complete list of a
2222
cachedir: .pytest_cache
2323
rootdir: /home/sweet/project
2424
collected 0 items
25-
cache -- .../_pytest/cacheprovider.py:528
25+
cache -- .../_pytest/cacheprovider.py:532
2626
Return a cache object that can persist state between testing sessions.
2727
2828
cache.get(key, default)

doc/en/changelog.rst

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,23 @@ with advance notice in the **Deprecations** section of releases.
2828

2929
.. towncrier release notes start
3030
31+
pytest 7.4.1 (2023-09-02)
32+
=========================
33+
34+
Bug Fixes
35+
---------
36+
37+
- `#10337 <https://github.com/pytest-dev/pytest/issues/10337>`_: Fixed bug where fake intermediate modules generated by ``--import-mode=importlib`` would not include the
38+
child modules as attributes of the parent modules.
39+
40+
41+
- `#10702 <https://github.com/pytest-dev/pytest/issues/10702>`_: Fixed error assertion handling in :func:`pytest.approx` when ``None`` is an expected or received value when comparing dictionaries.
42+
43+
44+
- `#10811 <https://github.com/pytest-dev/pytest/issues/10811>`_: Fixed issue when using ``--import-mode=importlib`` together with ``--doctest-modules`` that caused modules
45+
to be imported more than once, causing problems with modules that have import side effects.
46+
47+
3148
pytest 7.4.0 (2023-06-23)
3249
=========================
3350

0 commit comments

Comments
 (0)
0