mirror of
https://github.com/qdrant/qdrant.git
synced 2026-07-23 11:11:00 -05:00
CI: improve automatic issue creation (#2706)
* improve automatic issue creation - restrict to only create automatic issues on PRs of authors of the org, or on dev/main - modify link to failed job, currently this only applies to the issue reporting job, because it's hard to link them to the actual flaky failure run, but it already improves it. - reduce retries to only 2. Having 3 tries in total feels more than enough. * debug author association * ignore issue updating failure * cleanup
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
[profile.ci]
|
||||
# Retry tests before failing them.
|
||||
retries = { backoff = "exponential", count = 3, delay = "2s" }
|
||||
retries = { backoff = "exponential", count = 2, delay = "2s" }
|
||||
# Do not cancel the test run on the first failure.
|
||||
fail-fast = false
|
||||
# Print out output for failing tests as soon as they fail, and also at the end
|
||||
|
||||
4
.github/ISSUE_TEMPLATE/flaky_test.md
vendored
4
.github/ISSUE_TEMPLATE/flaky_test.md
vendored
@@ -12,7 +12,9 @@ title: Flaky test `{{ env.TEST_NAME }}`
|
||||
|
||||
### Context
|
||||
|
||||
[Flaky failure run](https://github.com/{{ env.REPOSITORY }}/actions/runs/{{ env.RUN_ID }})
|
||||
Date: {{ date | date('DD.MM.YYYY HH:mm') }}
|
||||
|
||||
[Flaky failure run](https://github.com/{{ env.REPOSITORY }}/actions/runs/{{ env.RUN_ID }}/job/{{ env.JOB_ID }})
|
||||
|
||||
[Commit](https://github.com/{{ env.REPOSITORY }}/tree/{{ env.SHA }})
|
||||
|
||||
|
||||
7
.github/workflows/rust.yml
vendored
7
.github/workflows/rust.yml
vendored
@@ -39,7 +39,8 @@ jobs:
|
||||
path: target/nextest/ci/junit.xml
|
||||
|
||||
# After tests are run, this hacky script will process the JUnit output of nextest
|
||||
# and will create a GH Issue if there is a test marked as flaky
|
||||
# and will create a GH Issue if there is a test marked as flaky,
|
||||
# Failure of updating an issue is ignored because it fails for external contributors.
|
||||
process-results:
|
||||
runs-on: ubuntu-latest
|
||||
needs: test
|
||||
@@ -71,13 +72,14 @@ jobs:
|
||||
echo "$(jq '[.flakyFailure] | flatten | .[0]["system-err"]' flaky_tests.json -r)" >> $GITHUB_OUTPUT
|
||||
echo $delimiter >> $GITHUB_OUTPUT
|
||||
- name: pull issue template
|
||||
if: ${{ steps.process-test-report.outputs.has_flaky_tests == 'true' }}
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
sparse-checkout: |
|
||||
.github/ISSUE_TEMPLATE/flaky_test.md
|
||||
sparse-checkout-cone-mode: false
|
||||
if: ${{ steps.process-test-report.outputs.has_flaky_tests == 'true' }}
|
||||
- name: Create issue for flaky tests
|
||||
continue-on-error: true
|
||||
id: create-issue
|
||||
if: ${{ steps.process-test-report.outputs.has_flaky_tests == 'true' }}
|
||||
uses: JasonEtco/create-an-issue@v2
|
||||
@@ -87,6 +89,7 @@ jobs:
|
||||
SYSTEM_ERROR: ${{ steps.get-flaky-tests.outputs.content }}
|
||||
REPOSITORY: ${{ github.repository }}
|
||||
RUN_ID: ${{ github.run_id }}
|
||||
JOB_ID: ${{ github.job }}
|
||||
SHA: ${{ github.sha }}
|
||||
WORKFLOW: ${{ github.workflow }}
|
||||
JOB: ${{ github.job }}
|
||||
|
||||
Reference in New Issue
Block a user