codecov / feedback

A place to discuss feedback about the pull request and web product experience.
37 stars 7 forks source link

[Self-hosted] Carryforward flags stopped working #535

Closed nikosatwork closed 1 month ago

nikosatwork commented 1 month ago

Describe the bug Carryforward flags stopped working after deleting some flags from the UI and leaving just the ones we are interested in.

Environment (please complete the following information):

To Reproduce Steps to reproduce the behavior:

  1. Update the CI/uploader to use two new flags
  2. Run the jobs and send the uploads with the new flags
  3. Go to Flags tab in the UI and delete all other flags, leaving just the two new flags
  4. Observe that carryforward flags do not work anymore, even after concecutive uploads

Expected behavior Carryforward flags should work and contain just the two new flags

Additional context The codecov.yml file contains:

flag_management:
  default_rules:
    carryforward: true

Thank you.

nikosatwork commented 1 month ago

cc @drazisil-codecov

nikosatwork commented 1 month ago

Note that the screenshots in the Carryforward Flags documentation is outdated

drazisil-codecov commented 1 month ago

@nikosatwork

To clarify, you deleted all flags excect the two you just uploaded coverage for, and then those flags did not carry forward? Was the commit a direct decendant of the commot where you uploaded the flags? I would search the logs for carryforward.

Mainly this one https://github.com/codecov/worker-archive/blob/9d11b1e745ea975bd9438a56b2965c4670c53026/services/report/__init__.py#L702

nikosatwork commented 1 month ago

Correct. I think so. It seems it took a while to propagate as after 4-5 uploads the two new flags started being carried forward.

Generally, is there a way to reset or flush the flags?

drazisil-codecov commented 1 month ago

Deleting them from the flags page in the UI should cause them to go away unless used again.

I think you may be able to safely delete them from the reports_repositoryflag table, but I have never tried.

nikosatwork commented 1 month ago

Thank you!