Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit15f93b3

Browse files
webknjazpatchback[bot]
authored andcommitted
Merge pull request#13933 from webknjaz/maintenance/tox-pep517-env-setuptools-scm-pretend-env-var
📦 Pass desired release to PEP 517 tox env(cherry picked from commitce8b8a7)
1 parent0fa11ae commit15f93b3

File tree

3 files changed

+25
-3
lines changed

3 files changed

+25
-3
lines changed

‎changelog/13933.contrib.rst‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
The tox configuration has been adjusted to make sure the desired
2+
version string can be passed into its:ref:`package_env` through
3+
the ``SETUPTOOLS_SCM_PRETEND_VERSION_FOR_PYTEST`` environment
4+
variable as a part of the release process -- by:user:`webknjaz`.

‎changelog/13933.packaging.rst‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
13933.contrib.rst

‎tox.ini‎

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,26 @@ envlist =
2323

2424

2525

26+
[pkgenv]
27+
# NOTE: This section tweaks how Tox manages the PEP 517 build
28+
# NOTE: environment where it assembles wheels (editable and regular)
29+
# NOTE: for further installing them into regular testenvs.
30+
#
31+
# NOTE: `[testenv:.pkg]` does not work due to a regression in tox v4.14.1
32+
# NOTE: so `[pkgenv]` is being used in place of it.
33+
# Refs:
34+
# * https://github.com/tox-dev/tox/pull/3237
35+
# * https://github.com/tox-dev/tox/issues/3238
36+
# * https://github.com/tox-dev/tox/issues/3292
37+
# * https://hynek.me/articles/turbo-charge-tox/
38+
#
39+
# NOTE: The `SETUPTOOLS_SCM_PRETEND_VERSION_FOR_PYTEST` environment
40+
# NOTE: variable allows enforcing a pre-determined version for use in
41+
# NOTE: the wheel being installed into usual testenvs.
42+
pass_env =
43+
SETUPTOOLS_SCM_PRETEND_VERSION_FOR_PYTEST
44+
45+
2646
[testenv]
2747
description =
2848
run the tests
@@ -49,7 +69,6 @@ passenv =
4969
COVERAGE_*
5070
PYTEST_ADDOPTS
5171
TERM
52-
SETUPTOOLS_SCM_PRETEND_VERSION_FOR_PYTEST
5372
CI
5473
setenv =
5574
_PYTEST_TOX_DEFAULT_POSARGS={env:_PYTEST_TOX_POSARGS_DOCTESTING:} {env:_PYTEST_TOX_POSARGS_LSOF:} {env:_PYTEST_TOX_POSARGS_XDIST:} {env:_PYTEST_FILES:}
@@ -141,8 +160,6 @@ setenv =
141160
description =
142161
regenerate documentation examples under `{basepython}`
143162
changedir = doc/en
144-
passenv =
145-
SETUPTOOLS_SCM_PRETEND_VERSION_FOR_PYTEST
146163
deps =
147164
PyYAML
148165
regendoc>=0.8.1

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp