-
Notifications
You must be signed in to change notification settings - Fork 624
Improve coverage report format in GitHub pull requests. #1377
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Binary Size ReportAffected SDKs
Test Logs |
Could the parsing logic be done in The motivation for |
I'm not sure I understand. What do you mean by doing it in |
You can extend https://github.com/firebase/firebase-android-sdk/tree/master/ci/fireci with custom commands, via So in your case you could invoke gradle and then do postprocessing on the expected output of the build. |
Calculate and upload coverage reports to our own Metrics Service instead of Codecov.
c50dc97
to
1366c0c
Compare
/test fireci |
/test smoke-tests |
ci/fireci/fireciplugins/coverage.py
Outdated
|
||
|
||
def construct_request_header(): | ||
result = subprocess.run(['gcloud', 'auth', 'print-identity-token'], stdout=subprocess.PIPE) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pls add:
result = subprocess.run(['gcloud', 'auth', 'print-identity-token'], stdout=subprocess.PIPE) | |
result = subprocess.run(['gcloud', 'auth', 'print-identity-token'], stdout=subprocess.PIPE, check=True) |
Otherwise you won't know if gcloud fails
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
additionally, this seems a good candidate for a cli flag as well with a default that makes the subprocess call, that way if one has a token it can be passed in without an additonal call to gcloud
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
ci/fireci/fireciplugins/coverage.py
Outdated
endpoint = construct_request_endpoint() | ||
headers = construct_request_header() | ||
|
||
print('Posting to the metrics service ...') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pls use logging.getLogger('fireci.coverage')
throughout.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
ci/fireci/fireciplugins/coverage.py
Outdated
return 0 | ||
|
||
|
||
def find_prow_job_link(): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider making this a flag and have its default
point to this function.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
ci/fireci/fireciplugins/coverage.py
Outdated
|
||
|
||
def post_request(data): | ||
metrics_service_url = os.getenv('METRICS_SERVICE_URL') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
consider making this an option with envvar="METRICS_SERVICE_URL"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By "option", do you mean a @click.option
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
Calculate and upload coverage reports to our own Metrics Service instead
of Codecov.