Skip to content

Permission denied error on macOS with v5 #1771

Closed

Description

@nmoinvaz

Describe the bug
Error:

codecov-action/v5/dist/codecov.sh: line 252: ./codecov: Permission denied

Log:

Run codecov/codecov-action@v5
Run CC_ACTION_VERSION=$(cat ${GITHUB_ACTION_PATH}/src/version)
==> Running Action version 5.3.1
Run git config --global --add safe.directory /Users/buildbox/Source/actions-runner/_work/client/client
Run CC_FORK="false"
Run if [ "false" == 'true' ] && [ "$CC_FORK" != 'true' ];
==> Token set from env
Run if [ -z "$CC_BRANCH" ] && [ -z "$CC_TOKEN" ] && [ "$CC_FORK" == 'true' ]
Run if [ -z "$CC_SHA" ];
Run ${GITHUB_ACTION_PATH}/dist/codecov.sh
     _____          _
    / ____|        | |
   | |     ___   __| | ___  ___ _____   __
   | |    / _ \ / _` |/ _ \/ __/ _ \ \ / /
   | |___| (_) | (_| |  __/ (_| (_) \ V /
    \_____\___/ \__,_|\___|\___\___/ \_/
                            Wrapper-0.1.0
                                  
==> Detected macos
 -> Downloading https://cli.codecov.io/latest/macos/codecov
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed

  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0 21.9M    0   99k    0     0   447k      0  0:00:50 --:--:--  0:00:50  446k
 47 21.9M   47 10.4M    0     0  8743k      0  0:00:02  0:00:01  0:00:01 8738k
 97 21.9M   97 21.3M    0     0  9845k      0  0:00:02  0:00:02 --:--:-- 9842k
100 21.9M  100 21.9M    0     0  9868k      0  0:00:02  0:00:02 --:--:-- 98[64](https://github.com/snxd/client/actions/runs/13418288950/job/37484513793?pr=2961#step:64:66)k
==> Finishing downloading macos:latest
      Version: v10.0.1
 
==> Bypassing validation...
 -> Token of length 36 detected
==> Running upload-coverage
      ./codecov upload-coverage -t <redacted> --fail-on-error --git-service github --sha 955337de135323eb2166b8a4fef06b6924fdb56f --flag macarm64 --gcov-executable gcov --name Coverage - macOS - Ninja Clang
/Users/buildbox/Source/actions-runner/_work/_actions/codecov/codecov-action/v5/dist/codecov.sh: line 252: ./codecov: Permission denied

To Reproduce

    - name: Publish coverage report
      uses: codecov/codecov-action@v5
      if: always() && !cancelled()
      with:
        token: ${{ secrets.CODECOV_TOKEN }}
        flags: ${{ matrix.codecov }}
        name: ${{ matrix.name }}
        verbose: false
        fail_ci_if_error: true
        skip_validation: true
      env:
        CODECOV_TOKEN: "${{ secrets.CODECOV_TOKEN }}"

Versions

  • OS: macOS 15 arm64
  • Git Host: GitHub self-hosted runner
  • CI/CD: GitHub Actions
  • Uploader: codecov-action@v5

Activity

  1. thomasrockhu-codecov commented on Feb 20, 2025

    @thomasrockhu-codecov
    Contributor

    @nmoinvaz can you run this in verbose mode?

  2. nmoinvaz commented on Mar 3, 2025

    @nmoinvaz
    Author

    Verbose shows nearly the same response.

    2025-03-03T17:03:38.4116680Z   CC_FORK: false
    2025-03-03T17:03:38.4117460Z   CC_TOKEN: ***
    2025-03-03T17:03:38.4118030Z   CC_BRANCH: 
    2025-03-03T17:03:38.4118550Z   CC_SHA: 6f60548891622147db78294faa003b96226df69a
    2025-03-03T17:03:38.4119180Z   CC_PR: 
    2025-03-03T17:03:38.4119710Z   CODECOV_TOKEN: ***
    2025-03-03T17:03:38.4120210Z   CC_BASE_SHA: 
    2025-03-03T17:03:38.4120700Z   CC_BINARY: 
    2025-03-03T17:03:38.4121180Z   CC_BUILD: 
    2025-03-03T17:03:38.4121650Z   CC_BUILD_URL: 
    2025-03-03T17:03:38.4122150Z   CC_CODE: 
    2025-03-03T17:03:38.4122630Z   CC_DIR: 
    2025-03-03T17:03:38.4123130Z   CC_DISABLE_FILE_FIXES: false
    2025-03-03T17:03:38.4123670Z   CC_DISABLE_SEARCH: false
    2025-03-03T17:03:38.4124200Z   CC_DISABLE_TELEM: false
    2025-03-03T17:03:38.4124720Z   CC_DRY_RUN: false
    2025-03-03T17:03:38.4125230Z   CC_ENTERPRISE_URL: 
    2025-03-03T17:03:38.4132510Z   CC_ENV: 
    2025-03-03T17:03:38.4133010Z   CC_EXCLUDES: 
    2025-03-03T17:03:38.4133520Z   CC_FAIL_ON_ERROR: true
    2025-03-03T17:03:38.4134040Z   CC_FILES: 
    2025-03-03T17:03:38.4134520Z   CC_FLAGS: macarm64
    2025-03-03T17:03:38.4135290Z   CC_FORCE: 
    2025-03-03T17:03:38.4135770Z   CC_GCOV_ARGS: 
    2025-03-03T17:03:38.4136280Z   CC_GCOV_EXECUTABLE: gcov
    2025-03-03T17:03:38.4136820Z   CC_GCOV_IGNORE: 
    2025-03-03T17:03:38.4137320Z   CC_GCOV_INCLUDE: 
    2025-03-03T17:03:38.4137830Z   CC_GIT_SERVICE: github
    2025-03-03T17:03:38.4138370Z   CC_HANDLE_NO_REPORTS_FOUND: false
    2025-03-03T17:03:38.4138940Z   CC_JOB_CODE: 
    2025-03-03T17:03:38.4139440Z   CC_LEGACY: false
    2025-03-03T17:03:38.4139980Z   CC_NAME: Coverage - macOS - Ninja Clang
    2025-03-03T17:03:38.4140620Z   CC_NETWORK_FILTER: 
    2025-03-03T17:03:38.4141120Z   CC_NETWORK_PREFIX: 
    2025-03-03T17:03:38.4141640Z   CC_NETWORK_ROOT_FOLDER: 
    2025-03-03T17:03:38.4142160Z   CC_OS: 
    2025-03-03T17:03:38.4142650Z   CC_PARENT_SHA: 
    2025-03-03T17:03:38.4143140Z   CC_PLUGINS: 
    2025-03-03T17:03:38.4143650Z   CC_RECURSE_SUBMODULES: false
    2025-03-03T17:03:38.4144190Z   CC_REPORT_TYPE: 
    2025-03-03T17:03:38.4144730Z   CC_RUN_CMD: upload-coverage
    2025-03-03T17:03:38.4145290Z   CC_SERVICE: github
    2025-03-03T17:03:38.4145810Z   CC_SKIP_VALIDATION: true
    2025-03-03T17:03:38.4146330Z   CC_SLUG: 
    2025-03-03T17:03:38.4146810Z   CC_SWIFT_PROJECT: 
    2025-03-03T17:03:38.4147330Z   CC_USE_PYPI: false
    2025-03-03T17:03:38.4147840Z   CC_VERBOSE: true
    2025-03-03T17:03:38.4148350Z   CC_VERSION: latest
    2025-03-03T17:03:38.4148870Z   CC_YML_PATH: 
    2025-03-03T17:03:38.4149380Z ##[endgroup]
    2025-03-03T17:03:38.5768150Z      _____          _
    2025-03-03T17:03:38.5779560Z     / ____|        | |
    2025-03-03T17:03:38.5783900Z    | |     ___   __| | ___  ___ _____   __
    2025-03-03T17:03:38.5785950Z    | |    / _ \ / _` |/ _ \/ __/ _ \ \ / /
    2025-03-03T17:03:38.5787890Z    | |___| (_) | (_| |  __/ (_| (_) \ V /
    2025-03-03T17:03:38.5790080Z     \_____\___/ \__,_|\___|\___\___/ \_/
    2025-03-03T17:03:38.5792160Z                            �[0;31m Wrapper-0.2.0�[0m
    2025-03-03T17:03:38.5792980Z                                   
    2025-03-03T17:03:38.5865930Z �[0;32m==>�[0m Detected �[0;36mmacos�[0m
    2025-03-03T17:03:38.5868950Z �[0;32m ->�[0m Downloading �[0;36mhttps://cli.codecov.io/latest/macos/codecov�[0m
    2025-03-03T17:03:38.5983150Z   % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
    2025-03-03T17:03:38.5985410Z                                  Dload  Upload   Total   Spent    Left  Speed
    2025-03-03T17:03:38.5985980Z 
    2025-03-03T17:03:39.3830740Z   0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
    2025-03-03T17:03:40.3830300Z  31 21.9M   31 7181k    0     0  9147k      0  0:00:02 --:--:--  0:00:02 9137k
    2025-03-03T17:03:40.7524840Z  81 21.9M   81 17.9M    0     0  10.0M      0  0:00:02  0:00:01  0:00:01 10.0M
    2025-03-03T17:03:40.7528200Z 100 21.9M  100 21.9M    0     0  10.2M      0  0:00:02  0:00:02 --:--:-- 10.2M
    2025-03-03T17:03:40.7542750Z �[0;32m==>�[0m Finishing downloading �[0;36mmacos:latest�[0m
    2025-03-03T17:03:40.9049990Z       Version: �[0;36mv10.2.0�[0m
    2025-03-03T17:03:40.9051680Z  
    2025-03-03T17:03:40.9052520Z �[0;31m==>�[0m Bypassing validation...
    2025-03-03T17:03:40.9229580Z �[0;32m ->�[0m Token of length 36 detected
    2025-03-03T17:03:41.0379750Z �[0;32m==>�[0m Running upload-coverage
    2025-03-03T17:03:41.0399650Z       �[0;36m./codecov --verbose upload-coverage -t <redacted> --fail-on-error --git-service github --sha 6f60548891622147db78294faa003b96226df69a --flag macarm64 --gcov-executable gcov --name Coverage - macOS - Ninja Clang�[0m
    2025-03-03T17:03:41.0405270Z /Users/buildbox/Source/actions-runner/_work/_actions/codecov/codecov-action/v5/dist/codecov.sh: line 253: ./codecov: Permission denied
    2025-03-03T17:03:41.0409000Z �[0;31m==> Failed to run upload-coverage�[0m
    2025-03-03T17:03:41.0410900Z �[0;31m    Exiting...�[0m
    2025-03-03T17:03:41.0420380Z ##[error]Process completed with exit code 1.

    Was there something you were looking for?

  3. nmoinvaz commented on Mar 3, 2025

    @nmoinvaz
    Author

    Maybe this has to do with skip_validation: true

  4. thomasrockhu-codecov commented on Mar 3, 2025

    @thomasrockhu-codecov
    Contributor

    @nmoinvaz oh! good catch, Ill push out a fix this week

  5. nmoinvaz commented on Mar 7, 2025

    @nmoinvaz
    Author

    Hi Thomas, just checking in to see if you were able to push this fix. Thanks!

  6. nmoinvaz commented on Mar 14, 2025

    @nmoinvaz
    Author

    Bump? :-)

  7. thomasrockhu-codecov commented on Mar 15, 2025

    @thomasrockhu-codecov
    Contributor

    Sorry @nmoinvaz this was a little more complicated than I expected. Hoping to get something out next week

  8. nmoinvaz commented on Mar 15, 2025

    @nmoinvaz
    Author

    Thanks! 🙏🏻

  9. nmoinvaz commented on Mar 29, 2025

    @nmoinvaz
    Author

    Any word?

  10. 8 remaining items

  11. jviall commented on Aug 19, 2025

    @jviall
    Contributor

    Just wanted to bump that I'm also hitting this still despite the fix--but probably because the main repo isn't using the latest wrapper? I did submit a PR to update that in order to fix #1863

    my CI output:
    Run ${GITHUB_ACTION_PATH}/dist/codecov.sh
      ${GITHUB_ACTION_PATH}/dist/codecov.sh
      shell: /bin/bash --noprofile --norc -e -o pipefail {0}
      env:
        OS: macos-latest
        PYTHON: 3.13
        CODECOV_TOKEN: ***
        pythonLocation: /Users/runner/hostedtoolcache/Python/3.13.5/arm64
        PKG_CONFIG_PATH: /Users/runner/hostedtoolcache/Python/3.13.5/arm64/lib/pkgconfig
        Python_ROOT_DIR: /Users/runner/hostedtoolcache/Python/3.13.5/arm64
        Python2_ROOT_DIR: /Users/runner/hostedtoolcache/Python/3.13.5/arm64
        Python3_ROOT_DIR: /Users/runner/hostedtoolcache/Python/3.13.5/arm64
        VENV: .venv/bin/activate
        CC_FORK: false
        CC_TOKEN: ***
        CC_BRANCH: 
        CC_SHA: ef2edf24740ca1c0021b71cca27bb06fd6e7930e
        CC_PR: 
        CC_BASE_SHA: 
        CC_BINARY: 
        CC_BUILD: 
        CC_BUILD_URL: 
        CC_CODE: 
        CC_DIR: .coverage
        CC_DISABLE_FILE_FIXES: false
        CC_DISABLE_SEARCH: false
        CC_DISABLE_TELEM: false
        CC_DRY_RUN: false
        CC_ENTERPRISE_URL: 
        CC_ENV: OS,PYTHON
        CC_EXCLUDES: 
        CC_FAIL_ON_ERROR: false
        CC_FILES: 
        CC_FLAGS: 
        CC_FORCE: 
        CC_GCOV_ARGS: 
        CC_GCOV_EXECUTABLE: gcov
        CC_GCOV_IGNORE: 
        CC_GCOV_INCLUDE: 
        CC_GIT_SERVICE: github
        CC_HANDLE_NO_REPORTS_FOUND: false
        CC_JOB_CODE: 
        CC_LEGACY: false
        CC_NAME: 
        CC_NETWORK_FILTER: 
        CC_NETWORK_PREFIX: 
        CC_NETWORK_ROOT_FOLDER: 
        CC_OS: 
        CC_PARENT_SHA: 
        CC_PLUGINS: 
        CC_RECURSE_SUBMODULES: false
        CC_REPORT_TYPE: 
        CC_RUN_CMD: upload-coverage
        CC_SERVICE: github
        CC_SKIP_VALIDATION: true
        CC_SLUG: 
        CC_SWIFT_PROJECT: 
        CC_USE_PYPI: false
        CC_VERBOSE: true
        CC_VERSION: latest
        CC_YML_PATH: 
         _____          _
        / ____|        | |
       | |     ___   __| | ___  ___ _____   __
       | |    / _ \ / _` |/ _ \/ __/ _ \ \ / /
       | |___| (_) | (_| |  __/ (_| (_) \ V /
        \_____\___/ \__,_|\___|\___\___/ \_/
                                Wrapper-0.2.1
    

    ==> Detected macos
    -> Downloading https://cli.codecov.io/latest/macos/codecov
    % Total % Received % Xferd Average Speed Time Time Time Current
    Dload Upload Total Spent Left Speed

    0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
    100 15.6M 100 15.6M 0 0 103M 0 --:--:-- --:--:-- --:--:-- 104M
    ==> Finishing downloading macos:latest
    Version: v11.1.0

    ==> Bypassing validation...
    -> Token of length 36 detected
    ==> Running upload-coverage
    ./codecov --verbose upload-coverage -t --git-service github --sha ef2edf24740ca1c0021b71cca27bb06fd6e7930e --env OS,PYTHON --dir .coverage --gcov-executable gcov
    /Users/runner/work/_actions/codecov/codecov-action/v5/dist/codecov.sh: line 253: ./codecov: Permission denied
    ==> Failed to run upload-coverage

  12. nmoinvaz commented on Aug 19, 2025

    @nmoinvaz
    Author

    I'm still getting the same error even when trying @main in my GH action.

  13. thomasrockhu-codecov commented on Aug 19, 2025

    @thomasrockhu-codecov
    Contributor

    @jviall @nmoinvaz this is my fault, I thought I had made a new release. I'll do that today

  14. thomasrockhu-codecov commented on Aug 19, 2025

    @thomasrockhu-codecov
    Contributor

    @nmoinvaz oh you mentioned main is also failing, can you shoot over a PR you see it on if possible?

  15. jviall commented on Aug 19, 2025

    @jviall
    Contributor

    @nmoinvaz oh you mentioned main is also failing, can you shoot over a PR you see it on if possible?

    It's because main is still referencing an old version of the wrapper (0.2.1). It's not targeting main but you can see the error occurring in this CI run of mine on a different project. I already put up a PR to try to upgrade the version of the wrapper--@thomasrockhu-codecov could you give it a review?

  16. thomasrockhu-codecov commented on Aug 20, 2025

    @thomasrockhu-codecov
    Contributor

    @jviall @nmoinvaz, I just pushed 5.5.0, let me know if that is working for you!

  17. nmoinvaz commented on Aug 20, 2025

    @nmoinvaz
    Author

    @thomasrockhu-codecov works good thank you! Feel free to close this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions