question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Upload not reading token from `.codecov.yml` nor `codecov.yml`

See original GitHub issue

When I tried running $ codecov in the root directory of the repository, I’m getting the following output:

  _____          _  
 / ____|        | |  
| |     ___   __| | ___  ___ _____   __  
| |    / _ \ / _` |/ _ \/ __/ _ \ \ / /  
| |___| (_) | (_| |  __/ (_| (_) \ V /  
 \_____\___/ \__,_|\___|\___\___/ \_/  
                                v2.2.0
YAML .codecov.yml
==> Detecting CI Provider
    No CI Detected. Using git/mercurial
==> Configuration: 
    Endpoint: https://codecov.io
{ commit: 'eb22cc3fcb7c17222366ed11b57ea5a1049fd7c2',
  branch: 'master',
  package: 'node-v2.2.0' }
==> Building file structure
==> Generating gcov reports (skip via --disable=gcov)
    $ find . -type f -name '*.gcno'  -exec gcov  {} +
==> Scanning for reports
    + ./foo/coverage/lcov.info
==> Uploading reports
    HTTP 400
Please provide the repository token to upload reports via `-t :repository-token`

even though there’s a token in my .codecov.yml. I did verify that the .codecov.yml is valid by running:

$ cat .codecov.yml | curl --data-binary @- https://codecov.io/validate

Upon digging into the code, I see these lines detect the codecov.yml file but don’t do anything with it.

I can put the token in process.env.CODECOV_TOKEN but I’m just wondering if it’s a mistake or by design that reading the token from the codecov.yml file isn’t supported.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:8
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
stevepeakcommented, Feb 13, 2018

If the yaml is not detected at .codecov.yml you may need to change the path to codecov.yml. Our detection occurs through the git ls-files in our backend.

If you would like us to manually change the location of the yaml please contact us in the in-app chat support with owner/repo @ .codecov.yml to adjust it.

Thank you, Steve

0reactions
hellatancommented, Aug 16, 2018

i submitted a PR for supporting either one of the yaml files: https://github.com/codecov/codecov-node/pull/108

Read more comments on GitHub >

github_iconTop Results From Across the Web

Frequently Asked Questions - Codecov
The unique repository upload token is found on the settings page of your project. ... No, Codecov will work without a yaml under...
Read more >
How can codecov verify a upload request without a token?
In this section, the codecov documentation says: The upload token is required for all uploads, except originating from public projects using ...
Read more >
How to Set Up Codecov with C and GitHub Actions in 2022
In other words, it tells you what percentage of your code is executed when you run your tests, and helps you find out...
Read more >
Codecov Security
When does Codecov read source code from my repository? ... with the User's Token; If the User does not have at least read...
Read more >
codecov/codecov - CircleCI Developer Hub
Upload your coverage reports to Codecov without dealing with ... Use CircleCI version 2.1 at the top of your .circleci/config.yml file.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found