Flags are not added on some jobs

Before submitting a topic, please confirm the following

I have searched for similar issues before creating this topic.
I have verified that my repository is using the Codecov GitHub app, if using GitHub
I have validated my codecov.yaml configuration file.
I have filled out the below sections to the best of my ability.

Description

Summary: Our flags view is not updating with newly added flags.

Context: We previously used CodeCov in this same monorepo, then deactivated it for a period of several months (not entirely sure why TBH), and are now in the process of reactivating.
The repo’s structure has gone through very significant changes since that time, but the flags view seems to be stuck with only the packages we’d previously uploaded.

CI/CD URL

Here is an upload job which succeeds.

Codecov Output

Please provide the full output of running the uploader on your CI/CD. This will typically have the Codecov logo as ASCII.

[2022-09-30T18:59:56.528Z] ['verbose'] Start of uploader: 1664564396528...
[2022-09-30T18:59:56.530Z] ['info'] 
     _____          _
    / ____|        | |
   | |     ___   __| | ___  ___ _____   __
   | |    / _ \ / _` |/ _ \/ __/ _ \ \ / /
   | |___| (_) | (_| |  __/ (_| (_) \ V /
    \_____\___/ \__,_|\___|\___\___/ \_/

  Codecov report uploader 0.3.2
[2022-09-30T18:59:56.534Z] ['info'] => Project root located at: /root/project
[2022-09-30T18:59:56.538Z] ['info'] -> No token specified or token is empty
[2022-09-30T18:59:56.538Z] ['verbose'] Start of network processing...
[2022-09-30T18:59:56.538Z] ['verbose'] Searching for files in /root/project
[2022-09-30T18:59:56.547Z] ['verbose'] coveragepy is not installed
[2022-09-30T18:59:56.547Z] ['info'] Searching for coverage files...
[2022-09-30T18:59:56.718Z] ['info'] Warning: Some files located via search were excluded from upload.
[2022-09-30T18:59:56.718Z] ['info'] If Codecov did not locate your files, please review https://docs.codecov.com/docs/supported-report-formats
[2022-09-30T18:59:56.719Z] ['verbose'] Preparing to clean the following coverage paths: packages/contracts-periphery/coverage.json,packages/contracts-periphery/coverage/coverage-final.json,packages/contracts-periphery/coverage/lcov.info
[2022-09-30T18:59:56.719Z] ['info'] => Found 3 possible coverage files:
  packages/contracts-periphery/coverage.json
  packages/contracts-periphery/coverage/coverage-final.json
  packages/contracts-periphery/coverage/lcov.info
[2022-09-30T18:59:56.719Z] ['verbose'] End of network processing
[2022-09-30T18:59:56.719Z] ['info'] Processing /root/project/packages/contracts-periphery/coverage.json...
[2022-09-30T18:59:56.720Z] ['info'] Processing /root/project/packages/contracts-periphery/coverage/coverage-final.json...
[2022-09-30T18:59:56.720Z] ['info'] Processing /root/project/packages/contracts-periphery/coverage/lcov.info...
[2022-09-30T18:59:56.726Z] ['info'] Detected CircleCI as the CI provider.
[2022-09-30T18:59:56.726Z] ['verbose'] -> Using the following env variables:
[2022-09-30T18:59:56.726Z] ['verbose']      CI: true
[2022-09-30T18:59:56.726Z] ['verbose']      CIRCLECI: true
[2022-09-30T18:59:56.726Z] ['verbose'] Using the following upload parameters:
[2022-09-30T18:59:56.726Z] ['verbose'] branch
[2022-09-30T18:59:56.726Z] ['verbose'] build
[2022-09-30T18:59:56.727Z] ['verbose'] buildURL
[2022-09-30T18:59:56.727Z] ['verbose'] commit
[2022-09-30T18:59:56.727Z] ['verbose'] job
[2022-09-30T18:59:56.727Z] ['verbose'] pr
[2022-09-30T18:59:56.727Z] ['verbose'] service
[2022-09-30T18:59:56.727Z] ['verbose'] slug
[2022-09-30T18:59:56.727Z] ['verbose'] name
[2022-09-30T18:59:56.727Z] ['verbose'] tag
[2022-09-30T18:59:56.727Z] ['verbose'] flags
[2022-09-30T18:59:56.727Z] ['verbose'] parent
[2022-09-30T18:59:56.728Z] ['info'] Pinging Codecov: https://codecov.io/upload/v4?package=uploader-0.3.2&token=*******&branch=ctb%2Ftest-cleanup&build=156286&build_url=https%3A%2F%2Fcircleci.com%2Fgh%2Fethereum-optimism%2Foptimism%2F156286&commit=79f79a421c5e59f9199f6d01a3f7df4c64046ca5&job=0&pr=&service=circleci&slug=ethereum-optimism%2Foptimism&name=&tag=&flags=&parent=
[2022-09-30T18:59:56.728Z] ['verbose'] Passed token was 0 characters long
[2022-09-30T18:59:56.728Z] ['verbose'] https://codecov.io/upload/v4?package=uploader-0.3.2&branch=ctb%2Ftest-cleanup&build=156286&build_url=https%3A%2F%2Fcircleci.com%2Fgh%2Fethereum-optimism%2Foptimism%2F156286&commit=79f79a421c5e59f9199f6d01a3f7df4c64046ca5&job=0&pr=&service=circleci&slug=ethereum-optimism%2Foptimism&name=&tag=&flags=&parent=
        Content-Type: 'text/plain'
        Content-Encoding: 'gzip'
        X-Reduced-Redundancy: 'false'
[2022-09-30T18:59:58.329Z] ['info'] https://app.codecov.io/github/ethereum-optimism/optimism/commit/79f79a421c5e59f9199f6d01a3f7df4c64046ca5
https://storage.googleapis.com/codecov/v4/raw/2022-09-30/D7AEF601B3B4D951893901777EBCB00B/79f79a421c5e59f9199f6d01a3f7df4c64046ca5/cc8d1d91-1b29-4bb3-ae99-f44d1342b3cb.txt?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=GOOG1EJOGFN2JQ4OCTGA2MU5AEIT7OT5Z7HTFOAN2SPG4NWSN2UJYOY5U6LZQ%2F20220930%2FUS%2Fs3%2Faws4_request&X-Amz-Date=20220930T185958Z&X-Amz-Expires=10&X-Amz-SignedHeaders=host&X-Amz-Signature=e6977a8655193367548a38b092073946ca56f2067f98596cee84a2d64920103f
[2022-09-30T18:59:58.329Z] ['verbose'] Returned upload url: https://storage.googleapis.com/codecov/v4/raw/2022-09-30/D7AEF601B3B4D951893901777EBCB00B/79f79a421c5e59f9199f6d01a3f7df4c64046ca5/cc8d1d91-1b29-4bb3-ae99-f44d1342b3cb.txt?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=GOOG1EJOGFN2JQ4OCTGA2MU5AEIT7OT5Z7HTFOAN2SPG4NWSN2UJYOY5U6LZQ%2F20220930%2FUS%2Fs3%2Faws4_request&X-Amz-Date=20220930T185958Z&X-Amz-Expires=10&X-Amz-SignedHeaders=host&X-Amz-Signature=e6977a8655193367548a38b092073946ca56f2067f98596cee84a2d64920103f
[2022-09-30T18:59:58.329Z] ['info'] Uploading...
[2022-09-30T18:59:58.521Z] ['info'] {"status":"success","resultURL":"https://app.codecov.io/github/ethereum-optimism/optimism/commit/79f79a421c5e59f9199f6d01a3f7df4c64046ca5"}
[2022-09-30T18:59:58.521Z] ['verbose'] End of uploader: 1993 milliseconds

Expected Results

I expected to see contracts-periphery in the flags view.

Actual Results

I only see what looks like an outdated set of flags.

Additional Information

  1. The command used is codecov --verbose --clean --flag contracts-periphery, but
    the flag does not appear in codecov.
  2. Here is that command in our circleci/config.yml file.
  3. Here is our codecov.yml.

Having thought about it more, I’d probably change the title of this issue to “Newly added flags do not appear”.

I’m wondering if we’d be best off to delete our codecov account and start again?

Update:

I identified an apparent config issue where the flag names set in the codecov.yml file didn’t match the names we were providing as arguments to the uploader.

However we now have them matching (ie. contracts-bedrock-tests in codecov.yml and circleci/config.yml), and still are not seeing the flags uploaded.

Hi @maurelian I took a look at your situation and the command for flags is --flags, it looks like you’re using --flag. Additionally, I don’t see that the flag info is making it to Codecov, can you try using --flags and trying again? If that doesn’t work for some reason, give me the commit SHA you attempted this on and I’ll dig in further for you.

1 Like

thanks my issue has been fixed.

1 Like

Oops. That fixed it for me, TYVM!

1 Like