ephraimbuddy commented on PR #37152:
URL: https://github.com/apache/airflow/pull/37152#issuecomment-1970701134

   > One more thing. I think I right now - the "upload-coverage" is not used by 
the test - at all from what I see. And the thing is - it was is implemented so 
that individual PRs are not sending coverage data to the server - because 
that's where the real "final" coverage is determined by combining all the 
coverage from all the tests for a given run are done. I am not sure if fhat's 
the case - looks like it's not handled the right way any more. @Taragolis - can 
you help with it?
   > 
   
   Given the function I have as upload-coverage, I think it still works the 
right way?
   ```python
       def upload_coverage(self) -> str:
           if self.event_name == "push" and self.head_repo == "apache/airflow" 
and self.ref == "refs/heads/main":
               return "true"
           return "false"
   ```
   We only upload coverage when the tests were run on the main branch.
   
   > BTW. I think the flaky tests might be because the coverage data is 
collected in memory with cov.collect(). I think that might have a huge 
side-effect on the whole test suite being run. I would say, possibly a better 
way to get the coverage in this case would be to produce the coverage xml file 
(as it was before) and to retrieve coverage information by parsing the xml. 
that is probably less invasive way of doing it, I am a litle afraid that 
enabling coverage for all PRs of all our contributors (including those that run 
on public runners) might introduce a great flakiness problem.
   >
   > When the error code is fixed, you should re-run this test with use public 
runners label to see if that is not somethng that will be happening
   
   Yeah, the failure needs to be investigated. I will check again and add the 
label
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to