File tree 1 file changed +16
-1
lines changed
1 file changed +16
-1
lines changed Original file line number Diff line number Diff line change 35
35
- '*/src/cbor/lib/*'
36
36
coverage-data-path : ${{ env.COVERAGE_DATA_PATH }}
37
37
38
+ # A token is used to avoid intermittent spurious job failures caused by rate limiting.
39
+ - name : Set up Codecov upload token
40
+ run : |
41
+ if [[ "${{ github.repository }}" == "arduino-libraries/ArduinoIoTCloud" ]]; then
42
+ # In order to avoid uploads of data from forks, only use the token for runs in the parent repo.
43
+ # Token is intentionally exposed.
44
+ # See: https://community.codecov.com/t/upload-issues-unable-to-locate-build-via-github-actions-api/3954
45
+ CODECOV_TOKEN="47827969-3fda-4ba1-9506-e8d0834ed88c"
46
+ else
47
+ # codecov/codecov-action does unauthenticated upload if empty string is passed via the `token` input.
48
+ CODECOV_TOKEN=""
49
+ fi
50
+ echo "CODECOV_TOKEN=$CODECOV_TOKEN" >> "$GITHUB_ENV"
51
+
38
52
- name : Upload coverage report to Codecov
39
- uses : codecov/codecov-action@v1
53
+ uses : codecov/codecov-action@v3
40
54
with :
41
55
file : " ${{ env.COVERAGE_DATA_PATH }}"
42
56
fail_ci_if_error : true
57
+ token : ${{ env.CODECOV_TOKEN }}
You can’t perform that action at this time.
0 commit comments