-
-
Couldn't load subscription status.
- Fork 2.9k
Some tox cleanups #13841
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Some tox cleanups #13841
Changes from all commits
65ede5b
0075c57
66429ce
20741b4
0ed35d5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| ``tox>=4`` is now required when contributing to pytest. |
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -1,7 +1,6 @@ | ||||||
| [tox] | ||||||
| isolated_build = True | ||||||
| minversion = 3.20.0 | ||||||
| distshare = {homedir}/.tox/distshare | ||||||
| requires = | ||||||
| tox >= 4 | ||||||
| envlist = | ||||||
| linting | ||||||
| py310 | ||||||
|
|
@@ -94,12 +93,14 @@ deps = | |||||
| xdist: pytest-xdist>=2.1.0 | ||||||
| xdist: -e . | ||||||
| {env:_PYTEST_TOX_EXTRA_DEP:} | ||||||
| # Can use the same wheel for all environments. | ||||||
| package = wheel | ||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm not sure what are the implications of this myself, so I'll leave it out of this PR. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The implications is as I described — tox will build a full project wheel when provisioning the env with |
||||||
| wheel_build_env = .pkg | ||||||
|
|
||||||
| [testenv:linting] | ||||||
| description = | ||||||
| run pre-commit-defined linters under `{basepython}` | ||||||
| skip_install = True | ||||||
| basepython = python3 | ||||||
| deps = pre-commit>=2.9.3 | ||||||
| commands = pre-commit run --all-files --show-diff-on-failure {posargs:} | ||||||
| setenv = | ||||||
|
|
@@ -127,7 +128,6 @@ setenv = | |||||
| [testenv:docs-checklinks] | ||||||
| description = | ||||||
| check the links in the documentation with `{basepython}` | ||||||
| basepython = python3 | ||||||
| usedevelop = True | ||||||
| changedir = doc/en | ||||||
| deps = -r{toxinidir}/doc/en/requirements.txt | ||||||
|
|
@@ -141,7 +141,6 @@ setenv = | |||||
| description = | ||||||
| regenerate documentation examples under `{basepython}` | ||||||
| changedir = doc/en | ||||||
| basepython = python3 | ||||||
| passenv = | ||||||
| SETUPTOOLS_SCM_PRETEND_VERSION_FOR_PYTEST | ||||||
| deps = | ||||||
|
|
@@ -194,7 +193,6 @@ commands = | |||||
|
|
||||||
| [testenv:release] | ||||||
| description = do a release, required posarg of the version number | ||||||
| basepython = python3 | ||||||
| usedevelop = True | ||||||
| passenv = * | ||||||
| deps = | ||||||
|
|
@@ -212,7 +210,6 @@ commands = python scripts/prepare-release-pr.py {posargs} | |||||
|
|
||||||
| [testenv:generate-gh-release-notes] | ||||||
| description = generate release notes that can be published as GitHub Release | ||||||
| basepython = python3 | ||||||
| usedevelop = True | ||||||
| deps = | ||||||
| pypandoc | ||||||
|
|
||||||
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is good, just to note that in CI we always test with the wheel built with
hynek/build-and-inspect-python-package:pytest/.github/workflows/test.yml
Line 284 in fd7742e
I understand the motivation of the change here in
tox.iniis to speed up usingtoxlocally.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's actually about skipping the sdist build that's significant here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Though, you probably want
editableinstead. Locally, that is. And for CI we should build the dists once like I do everywhere and pass that to tox..There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree, and that what's done today already (unless I'm missing something).
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right, I was reviewing from mobile and didn't check. It is integrated indeed.