Updates to .codecov.yml

On this pull request, we changed the threshold for codecov project to 1%: https://github.com/publiclab/plots2/pull/7106.
Our .codecov.yml file looks like this now:

  layout: "reach, diff, flags, files"
  behavior: default
  require_changes: false  # if true: only post the comment if coverage changes
  require_base: no        # [yes :: must have a base report to post]
  require_head: yes       # [yes :: must have a head report to post]
  branches: null          # branch names that can post comment
        threshold: 1%
    patch: on

Unfortunately, the codecov report says the pull request decreases coverage by less than 1% and yet the test fails although it is under the set threshold. Is the syntax wrong somewhere?
Thank you so much for helping us work on this open source project with this tool!

Hi @halcyon

It’s possible that we aren’t reading the yaml file due to an error. Can you share a commit SHA so I can take a look?

First reaction is that patch: on can probably be deleted since it’s enabled by default and the way it’s currently written may be invalid.

Thanks! I actually managed to solved it by renaming the file to .codecov.yml

1 Like