File tree Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Original file line number Diff line number Diff line change 50
50
- name : Display code coverage report
51
51
run : coverage report
52
52
53
+ # A token is used to avoid intermittent spurious job failures caused by rate limiting.
54
+ - name : Set up Codecov upload token
55
+ run : |
56
+ if [[ "${{ github.repository }}" == "arduino/report-size-deltas" ]]; then
57
+ # In order to avoid uploads of data from forks, only use the token for runs in the parent repo.
58
+ # Token is intentionally exposed.
59
+ # See: https://community.codecov.com/t/upload-issues-unable-to-locate-build-via-github-actions-api/3954
60
+ CODECOV_TOKEN="3889efcb-4ed3-4d07-980a-99a3896bd9b8"
61
+ else
62
+ # codecov/codecov-action does unauthenticated upload if empty string is passed via the `token` input.
63
+ CODECOV_TOKEN=""
64
+ fi
65
+ echo "CODECOV_TOKEN=$CODECOV_TOKEN" >> "$GITHUB_ENV"
66
+
53
67
- name : Upload coverage report to Codecov
54
68
uses : codecov/codecov-action@v3
55
69
with :
56
70
file : ${{ env.COVERAGE_DATA_FILENAME }}
57
71
fail_ci_if_error : true
72
+ token : ${{ env.CODECOV_TOKEN }}
Original file line number Diff line number Diff line change 1
1
coverage == 7.2.7
2
- pytest == 7.3.2
2
+ pytest == 7.4.0
3
3
pytest-mock == 3.11.1
You can’t perform that action at this time.
0 commit comments