Add pytest-sentry
for pytest runs
#7186
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR helps us to collect statistics about flaky tests.
For the
pytest-sentry
it is necessary to specifyPYTEST_SENTRY_DSN
.There are several options for implementing it in our GitHub Actions. We discussed all of them within the
dev
team and came to a conclusion to store thePYTEST_SENTRY_DSN
as a repository secret.For the secret to be accessible from
!PR.yml
it is necessary to change the environment in which this workflow runs from unprivileged to privileged (frompull_request
topull_request_target
). To protect access from the forks PR to the main secrets, thegatekeeper
job was introduced.It is only possible to pass the gatekeeper for users with the "write" (or higher) permission.
In the case, the user doesn't have write access, the gatekeeper will not allow the user to perform some of the tests:
Related:
pytest
tests #7134Refs: