Commit Graph

163 Commits

Author SHA1 Message Date
dependabot[bot] 3a58fc2d44
build(deps): Bump peter-evans/create-pull-request from 3.7.0 to 4.2.3
Bumps [peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request) from 3.7.0 to 4.2.3.
- [Release notes](https://github.com/peter-evans/create-pull-request/releases)
- [Commits](2455e15969...2b011faafd)

---
updated-dependencies:
- dependency-name: peter-evans/create-pull-request
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-12-05 03:15:13 +00:00
Ashish Kurmi 1ada62e237
Update dependabot for GitHub Actions (#10464)
Signed-off-by: Ashish Kurmi <akurmi@stepsecurity.io>

Signed-off-by: Ashish Kurmi <akurmi@stepsecurity.io>
2022-11-04 07:41:34 -03:00
Bruno Oliveira deae8f47f6 Use specific tag in the gh-action-pypi-publish action
Otherwise we see this warning:

Warning:  You are using "pypa/gh-action-pypi-publish@master". The "master" branch of this project has been sunset and will not receive any updates, not even security bug fixes. Please, make sure to use a supported version. If you want to pin to v1 major version, use "pypa/gh-action-pypi-publish@release/v1". If you feel adventurous, you may opt to use use "pypa/gh-action-pypi-publish@unstable/v1" instead. A more general recommendation is to pin to exact tags or commit shas.
2022-10-24 19:23:40 -03:00
Klaus Rettinghaus 2b552c2240
update actions 2022-10-24 14:58:03 +02:00
Bruno Oliveira d84ed48f39
Merge pull request #10409 from pytest-dev/asottile-patch-1
allow jobs to pass if codecov.io fails
2022-10-22 10:00:32 -03:00
Anthony Sottile d352098261
allow jobs to pass if codecov.io fails 2022-10-21 13:11:43 -04:00
Anthony Sottile 508be0b2bf add -pylib tox environment 2022-10-20 17:15:57 -04:00
Anton Yakutovich d0abfb1c2a
Bump actions in test.yml 2022-10-09 16:27:35 +04:00
Ran Benita a501518a26
Revert "ci: fix PR not triggering workflows by switching back to pytestbot access token" 2022-10-08 00:58:51 +03:00
Ran Benita 2df0d9656c ci: fix PR not triggering workflows by switching back to pytestbot access token
The builtin actions token is not allowed to trigger further workflows.
So when we create a PR using that token, the PR checks don't run, and a
maintainer must close & open the PR to make them run. This is quite
annoying, so switch back to the "machine user" approach.

Fixes #9554.
2022-10-06 21:14:24 +03:00
John Litborn 69f2855cc8
fallback to native traceback when handling ExceptionGroup (take 2) [SQUASH] (#10209)
* Squashed commit of the following:

commit 41d339c46763bbe26123e1e6504b6e32290e33e1
Author: Cheukting <cheukting.ho@gmail.com>
Date:   Thu Jun 23 17:01:04 2022 +0800

    test in all py versions

commit b3572a5a12672228c3276fc8c8e05980dfb7888a
Author: Cheukting <cheukting.ho@gmail.com>
Date:   Thu Jun 23 16:41:06 2022 +0800

    add test

commit 7166a2a51e4f99046b028b663c193d8b558c7fd4
Author: Cheukting <cheukting.ho@gmail.com>
Date:   Thu Jun 23 16:00:07 2022 +0800

    update changelog

commit b958c73d489157f0c0d4e46425083a5e2e2bc851
Author: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Date:   Thu Jun 23 07:50:52 2022 +0000

    [pre-commit.ci] auto fixes from pre-commit.com hooks

    for more information, see https://pre-commit.ci

commit ea7f376c6ca37c40c83df0e4a1cfaaedb34bae91
Author: Cheukting <cheukting.ho@gmail.com>
Date:   Thu Jun 23 15:48:21 2022 +0800

    Fix MyPy

commit 97469beb1da40257e9a061a5e19548546c9312c4
Author: Cheukting <cheukting.ho@gmail.com>
Date:   Thu Jun 23 15:03:48 2022 +0800

    fix if ExceptionGroup not exist

commit 84e553642cd69b4d499231d733df91ebfa84c7ad
Author: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Date:   Thu Jun 23 03:43:27 2022 +0000

    [pre-commit.ci] auto fixes from pre-commit.com hooks

    for more information, see https://pre-commit.ci

commit 76bbef449b88bbd74fb5cca3b5293337a624ef03
Author: Cheukting <cheukting.ho@gmail.com>
Date:   Thu Jun 23 11:40:41 2022 +0800

    adding changelog

commit db82bebc5a4969e2083adcd97bdfd2a63bb17d98
Author: Cheukting <cheukting.ho@gmail.com>
Date:   Thu Jun 23 11:33:10 2022 +0800

    fall back to native when handeling to exception groups

* Typed ExceptionGroupTypes and changed to BaseExceptionGroup, fixed exceptionchain (excinfo->excinfo_, set reprcrash. Extended tests, though they're wip.

* added exceptiongroup to pre-commit-config, moved away from tuple to directly defining BaseExceptionGroup, added block comment, added match line for inner exception, changked mark.skipif to importorskip to not need top-level import, changed tox.ini a bit - only uncovered should now be py37 without exceptiongroup, due to hypothesis

* added py311-exceptiongroup to github CI, exceptiongroup is now a hard dependency on py<3.11, renamed bad variable names

* added use_coverage to ubuntu-py311

* import BaseExceptionGroup with explicit version check instead of try/catch

* removed from CI, added comments to tox and pre-commit
2022-08-17 09:16:32 -07:00
Bruno Oliveira 4c16b5af03 Split test/deploy workflows
This will trigger a deploy directly when a tag is pushed, avoiding
having to wait for another lenghty build.

This is safe since we only push release tags after the release PR has passed all its tests.

See comments in #9793.
2022-03-19 09:04:41 -03:00
Bruno Oliveira b79eff065e
Enable testing with Python 3.11 (#9511) 2022-02-11 15:20:42 +00:00
Bruno Oliveira 6828ec2f9b
Merge pull request #9669 from hugovk/ci-only-update-plugin-list-for-upstream 2022-02-11 09:24:09 -03:00
Hugo van Kemenade eb8a3ef849 Only update the plugin for upstream 2022-02-11 14:03:22 +02:00
Hugo van Kemenade be0c41bf8e
CI: Test latest 3.10 available 2022-02-11 13:49:11 +02:00
Florian Bruhin dff1a15881
ci: Add missing macOS CI envs (#9601)
alinsa_vix in Discord noticed that we are not testing Python 3.9 and 3.10 on macOS, which seems strange. Maybe this is due how to macOS CI resources were quite scarce for a while, but I believe this has improved since.
2022-02-04 12:11:30 +01:00
Florian Bruhin 6e1445b521
ci: Bump up timeout (#9560)
macOS apparently can be slow, https://github.com/pytest-dev/pytest/runs/4965510831 for #9556 got cancelled at 91%
2022-01-27 13:33:20 +01:00
Florian Bruhin d60771f986
ci: Try backporting via pull_request_target (#9430)
* ci: Try backporting via pull_request_target

* ci: Security improvements
2022-01-03 14:14:40 +00:00
Hugo van Kemenade 819c67f58e Also test branches prefixed test-me- 2022-01-01 23:36:10 +02:00
Ran Benita b9663fed6f
Merge pull request #9442 from hramezani/drop_python_36
Drop Python3.6 in CI, setup.cfg, and readme.
2021-12-30 12:22:13 +02:00
Ran Benita 1522afa1cd ci: run plugins job with python 3.9 instead of 3.7
Latest Django release dropped support for 3.7.
2021-12-28 11:01:23 +02:00
Hasan Ramezani 5599c5ad45
Drop Python3.6 in CI, setup.cfg, and readme. 2021-12-26 21:08:37 +01:00
Bruno Oliveira 913439f5e5 Fix test_errors_in_xfail_skip_expressions for Python 3.10.1
Decided to remove the condition altogether as seems reasonable to state
that our own test suite requires Python 3.10.1.

Fix #9413
2021-12-16 10:18:07 -03:00
Ran Benita c85b14391d ci: add a workflow for backporting to other branches
To backport a PR, e.g. 1000, to another branch, e.g. `7.0.x`, add a
label `backport 7.0.x` to the PR. This will trigger a workflow which
will create a branch `backport-1000-to-7.0.x` based on the `7.0.x`
branch with a cherry-pick of the PR's merge commit, and create a new PR
for it against the `7.0.x` branch.

It is very simplistic, for instance it doesn't handle cherry-pick
failure gracefully, doesn't validate the state of the PR, doesn't check
if the branch already exists, etc. But we can improve on it later as
needed.

Finally, PRs created by github actions do not themselves trigger further
actions, i.e. the PR isn't checked. You need to close & reopen the PR
for the checks to trigger. There are workarounds for this but they are
either less secure or require more setup.
2021-12-12 01:12:35 +02:00
Cristian Vera f288afde1d
Use codecov github action instead of deprecated bash uploader (#9252)
Fixes #9202.
2021-11-01 17:41:56 +02:00
Ran Benita 69b0a7b306
ci: remove linting job - covered be pre-commit.ci (#9247) 2021-10-29 19:23:47 -03:00
andrewdotn bcad6e8e9a
Make plugin list in PDF docs readable (#9241)
The current PDF docs attempt to format the list of all plugins as a
table, without any word-wrapping of the plugin description. That results
in almost all the information getting cut off. This PR formats the same
information into more of a paragraph format for the PDF, with nothing
cut off.

Fixes #451
2021-10-28 11:31:52 +03:00
Alexander King 14e032088c
Change the command for package building in release CI workflow (#9229) 2021-10-25 21:32:12 +03:00
Ronny Pfannschmidt 0892c77bc6 fixes #8133: mitigate regendoc issues wrt PRETEND_VERSION
this issues is less likely to hit due to the recent regendoc release
which includes a wheel

* migrate to setuptools_scm 6.3.2
* use SETUPTOOLS_SCM_PRETEND_VERSION_FOR_PYTEST
2021-10-02 20:22:18 +02:00
Bruno Oliveira 675f8da3a1 Fix prepare-release-pr invocation with empty --prerelease argument 2021-08-27 14:46:28 -03:00
Bruno Oliveira 9501e54852 'prerelease' input is not required in prepare-release-pr workflow
The default is the correct value when generating a normal release.
2021-08-27 14:26:30 -03:00
Florian Bruhin 4d965557e2
ci: Persist git credentials for prepare-release-pr (#8813)
See #8599, follow-up to #8681
2021-06-28 20:58:55 +02:00
Florian Bruhin c19f63d39d
Adjust releasing infra/docs (#8795)
* Adjust releasing infra/docs

Follow-up for #8150, see #7507

* Add suggestions
2021-06-28 12:24:48 +02:00
Bruno Oliveira 0d6cb3b281
Allow prereleases from prepare-release workflow (#8628)
Fix #7551
2021-06-24 18:05:56 +00:00
Ran Benita 864a2bc0a3 ci: use GitHub Actions token instead of `chatops`/`release_notes` secrets
It seems more secure to use the controlled & limited token than an
ambient secret.
2021-05-18 16:05:14 +03:00
Ran Benita 6bc6ec323a ci: reduce workflow permissions
Decrease security exposure by restricting what the code executing in the
actions is allowed to do (in terms of GitHub operations).
2021-05-18 16:05:14 +03:00
Florian Bruhin 3f71d63067 ci: Force colors on
See #7443
2021-05-04 17:55:47 +02:00
Bruno Oliveira 8c65a4f174 Configure support for Python 3.10 2021-03-26 07:33:24 -03:00
Simon K a6cf0a0a0e
rename master to main in PULL_REQUEST_TEMPLATE.md (#8481) 2021-03-22 22:06:46 +00:00
Ronny Pfannschmidt dbed1ff68f adopt main terminology in the configs
ref pytest-dev/meta#8
2021-03-09 22:35:34 +01:00
Bruno Oliveira e3c0fd3203 Update plugin-list every Sunday instead of everyday
Every day seems a bit excessive lately, let's make it less frequent.
2021-02-05 07:29:12 -03:00
Ran Benita c971f2f474 ci: give pytest bot the credit for updating the plugin list 2021-01-30 13:04:10 +02:00
Maximilian Cosmo Sitter beda7a8a31
Add plugin list 2021-01-29 16:19:54 +02:00
antonblr 8550c29180 coverage: Include code that runs in subprocesses 2020-12-26 16:59:07 -08:00
Anthony Sottile 293a7c962d
Use new pypy3 github actions syntax 2020-12-18 10:45:28 -08:00
Anthony Sottile 4da445dc2e
Revert "infra: Temporary pin setup-python GH action to v2.1.4" 2020-12-18 10:44:20 -08:00
antonblr 1264404fe7 infra: Temporary pin setup-python GH action to v2.1.4 2020-12-17 21:01:20 -08:00
Bruno Oliveira a1c5111a40 Fix events variable in prepare-release-pr.yml 2020-12-16 07:53:05 -03:00
Bruno Oliveira f1a1de2257
Use manual trigger to prepare release PRs (#8150)
Co-authored-by: Ran Benita <ran@unusedvar.com>
2020-12-16 07:50:02 -03:00
Anton cf1051cfba
infrastructure: Stricter tox dependensies (#8119) 2020-12-12 18:08:15 +02:00
Ran Benita 537215a16c
Merge pull request #7987 from bluetech/ci-deprecated
ci: fix deprecation message & couple updates
2020-11-16 23:29:35 +02:00
Ran Benita 701ff1f5a1 ci: only deploy to PyPI on X.Y.Z{,rcN} tags
We want to reserve other tags for our own purposes without it creating a
release.
2020-11-13 12:38:30 +02:00
Ran Benita 8aa9ea95e1 ci: test on Python 3.9 final 2020-11-01 09:49:41 +02:00
Ran Benita 76226182ae ci: change cache action to v2
Supposed to be faster.
2020-11-01 09:49:41 +02:00
Ran Benita f9d82a34f4 ci: replace deprecated ::set-env 2020-11-01 09:49:23 +02:00
Thomas Grainger e14b724ff4
Update .github/ISSUE_TEMPLATE/2_feature_request.md 2020-10-23 22:35:56 +01:00
Thomas Grainger 03363473f7
expand feature request issue template 2020-10-23 14:03:24 +01:00
Ran Benita fe69d0d680 ci: decrease job timeout from 6 hours to 30 minutes
We don't have any jobs that should go beyond that, so let's be nicer to
the CI host and quicker to report the failure.
2020-10-21 10:17:25 +03:00
Hugo van Kemenade 3059caf1ee
Put smoke test deps in requirements.txt for Dependabot (#7806) 2020-10-10 18:51:35 +03:00
Anthony Sottile 179f4326df py36+: drop python3.5 in CI and setup.cfg 2020-10-02 14:00:11 -07:00
Ran Benita 32bb8f3a63 Bump attrs requirement from >=17.4.0 to >=19.2.0
This allows us to remove the `ATTRS_EQ_FIELD` thing which is causing
some annoyance.
2020-09-27 13:17:59 +03:00
Bruno Oliveira 050c2df737
Use multiple issue template types and mention Discussions (#7739) 2020-09-21 20:22:25 +02:00
Sorin Sbarnea b031a7cecf
Smoke tests for assorted plugins (#7721)
Co-authored-by: Bruno Oliveira <nicoddemus@gmail.com>
Co-authored-by: Thomas Grainger <tagrain@gmail.com>
Co-authored-by: Kyle Altendorf <sda@fstab.net>
2020-09-19 15:56:52 -03:00
Anthony Sottile a5fd2895b6
Update to deadsnakes/action@v2.0.0
should be a noop (despite the major version bump) -- I rewrote the action to be more stable and need fewer security updates
2020-09-13 12:55:56 -07:00
Bruno Oliveira c871d8b2b6
Merge pull request #7304 from asottile/cache_pre_commit
cache the pre-commit environment
2020-06-09 10:56:42 -03:00
Gleb Nikonorov 96d4e2f571 Add documentation on closing issues 2020-06-08 23:58:44 -04:00
Anthony Sottile 8cca023840 cache the pre-commit environment 2020-06-02 12:30:10 -07:00
Ran Benita 9214e63af3
ci: use fetch-depth: 0 instead of fetching manually (#7297) 2020-06-02 10:29:36 +03:00
Anthony Sottile c9abdaf381 Use deadsnakes/action@v1.0.0 to install python3.9 nightly 2020-05-23 19:51:51 -07:00
Ran Benita c66bf59fd5
ci: update github action versions, remove outdated comment (#7177) 2020-05-08 13:03:51 +03:00
Anthony Sottile dad328bc8a Fix tests for python3.9 2020-05-07 05:26:55 -07:00
Bruno Oliveira fd2f172258 Let unittest frameworks deal with async functions
Instead of trying to handle unittest-async functions in pytest_pyfunc_call,
let the unittest framework handle them instead.

This lets us remove the hack in pytest_pyfunc_call, with the upside that
we should support any unittest-async based framework.

Also included 'asynctest' as test dependency for py37-twisted, and renamed
'twisted' to 'unittestextras' to better reflect that we install 'twisted' and
'asynctest' now.

This also fixes the problem of cleanUp functions not being properly called
for async functions.

Fix #7110
Fix #6924
2020-05-01 15:10:28 -03:00
Ran Benita 2cc3227f6a ci: twisted and oldattrs tox envs are now incompatible, don't run them together
twisted started to use `attr.s(eq)` argument which was added recently,
so it fails with oldattrs. One of the CI jobs ran twisted and oldattrs
together, so it started to fail.

Move the twisted code to be covered by another job, and remove it from
the job with the oldattrs.
2020-03-21 16:22:33 +02:00
Bruno Oliveira a0ea300e96 Fix bot trigger event
Issue events don't contain a 'comment' entry:
https://developer.github.com/v3/issues/events/#response-2

Issue comments also contain the original issue body:
https://developer.github.com/v3/activity/events/types/#issuecommentevent

That's why it was triggering even for comments on the issue.

Also changed to startsWith because there's no need to support
the command anywhere in the body IMO.

Fix #6895
2020-03-11 09:54:56 -03:00
Bruno Oliveira 15e1dd0f87
Automate release by comment notifications (#6823)
* Automate release by comment notifications

* Only run if @pytestbot is mentioned
2020-03-01 14:46:35 -03:00
Ran Benita c3e53a072d Switch to new git workflow
Co-Authored-By: Daniel Hahler <git@thequod.de>
2020-02-12 09:49:21 +02:00
Bruno Oliveira 1480aa31a7
Explicitly state on the PR template that we can squash commits (#6662)
* Explicitly state on the PR template that we can squash commits

This way we don't need to ask every time, and users who for some reason
would not like us to squash their commits can explicitly state so.
2020-02-03 14:35:50 -03:00
Daniel Hahler b2e6f66438 ci: GHA: run less jobs with coverage
This often might be causing for jobs to take longer than 10 minutes,
which is a timeout Codecov uses to wait for successful CI.

Also it is good in general to have CI finish faster, of course.
2020-01-28 17:38:53 +01:00
Daniel Hahler 934f38995a ci: GHA: codecov: set CODECOV_NAME, OS in flags 2020-01-24 19:42:51 +01:00
Daniel Hahler e5a362d0f5 ci: GHA: use scripts/report-coverage.sh 2020-01-24 18:00:38 +01:00
Daniel Hahler c051a9e7b9 ci: GHA: separate jobs for linting, docs, doctesting
It helps to know upfront that e.g. linting failed, and makes finding the
error easier.
2020-01-24 12:29:35 +01:00
Daniel Hahler a8d67f5e7b ci: codecov: add flags for GHA/Travis
This would help with debugging missing coverage when removing Travis
jobs.
2020-01-23 15:41:41 +01:00
Daniel Hahler 9869a3d9e1 ci: GHA: remove unnecessary check for `success()`
Following jobs get aborted on failure.

Ref: https://github.com/pytest-dev/pytest/pull/6530
2020-01-21 21:44:49 +01:00
Daniel Hahler ea31649062 ci: github actions: only deploy pytest-dev/pytest 2020-01-16 13:57:46 +01:00
Bruno Oliveira 1d3f27cef0 Add deploy step: publish package and release notes
Fix #6369
2020-01-15 08:11:35 -03:00
Bruno Oliveira d291905825 Append token to codecov.yml instead of duplicating the file 2020-01-14 07:47:21 -03:00
Bruno Oliveira a3bc6df950 Implement code coverage in GitHub actions
This overwrites the `codecov.yml` file in the root of the repository with
`codecov-upstream.yml` file (which contains the code-cov token)´, so PRs
and branches on the repository can upload coverage.

Suggestion from here:

https://github.com/pytest-dev/pytest/pull/6421#issuecomment-571934112

Security concerns: the token might be misused, but only to upload bogus coverage
to `codecov.io`, so the team believe this is harmless. If we decide to fallback
from this decision , we just need to revoke the token.

Related to #6369
2020-01-11 12:21:20 -03:00
Bruno Oliveira d76aa8b428 Add GitHub actions for CI
This includes our current full matrix (windows, linux and macos), for evaluting
purposes.

We should disconsider failures when evaluating PRs.

TODO:

- deploy
- coverage
- github release notes

Even with the above missing, I still believe it would be nice to merge
this and have GitHub actions working in parallel so we can evaluate performance
and usability from now on.
2019-12-19 11:06:57 -03:00
Bruno Oliveira 36ef545b2d Improve instructions on how to write CHANGELOG entries
This makes easier for contributors to get the CHANGELOG entry
right the first time.
2019-11-19 14:15:55 -03:00
Hugo 48ec7d28c6 Make whole checklist a comment to avoid incomplete TODOs in PRs 2019-11-14 12:01:40 +02:00
Hugo 350c27c8b4 Update text in PR template 2019-11-14 11:36:47 +02:00
Bruno Oliveira beb457c75e Add new 'improvement' changelog category
This creates a separate section from 'features' for small changes which
don't usually require user intervention, such as:

* Human readable session duration
* New junitxml fields
* Improved colors in terminal
* etc.

The idea is to better match user expectations about new actual
features in the "Features" section of the changelog.
2019-08-10 09:33:51 -03:00
Florian Bruhin 2479a91e92
Add Open Collective to FUNDING.yml 2019-06-27 17:53:03 +02:00
Bruno Oliveira e393a73890 Small change to test if pushing directly to master is disabled 2019-05-24 12:11:15 -03:00
Bruno Oliveira aaea4e52ef
Fix whitespace in FUNDING.yml 2019-05-23 12:44:55 -03:00
Bruno Oliveira 0cacdadc97
Create FUNDING.yml
Following instructions from:

* https://tidelift.com/subscription/how-to-connect-tidelift-with-github
* https://help.github.com/en/articles/displaying-a-sponsor-button-in-your-repository#displaying-a-sponsor-button-in-your-repository
2019-05-23 12:36:46 -03:00
Bruno Oliveira 0571e1ee8e Make it clear that small typos in docs don't require a CHANGELOG entry
From: https://github.com/pytest-dev/pytest/pull/5273#issuecomment-493076587
2019-05-16 10:54:50 -03:00
Daniel Hahler 3df32e2732 GitHub: revisit issue/PR templates [ci skip]
The motivation here is to not have the same boilerplate with PRs.
2019-04-23 18:01:13 +02:00
Bruno Oliveira f2174c16cc Add rtd-bot configuration file [skip appveyor] [skip travis]
Part of the configuration necessary for https://github.com/apps/rtd-helper
2019-01-13 20:38:19 -02:00