Skip to content
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

ci: Safe commenting on PRs #1729

Merged
merged 14 commits into from
Mar 11, 2024
Merged

Conversation

larseggert
Copy link
Collaborator

This generalizes and refactors what the QNS workflow did.

This generalizes and refactors what the QNS workflow did.
@larseggert larseggert mentioned this pull request Mar 11, 2024
Copy link

codecov bot commented Mar 11, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.45%. Comparing base (c551f49) to head (8bfde5c).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1729      +/-   ##
==========================================
+ Coverage   89.42%   89.45%   +0.02%     
==========================================
  Files         124      124              
  Lines       38887    38887              
==========================================
+ Hits        34775    34785      +10     
+ Misses       4112     4102      -10     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Collaborator

@mxinden mxinden left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for pulling this into separate actions! Overall looks good to me. Couple of nits / questions.

uses: actions/upload-artifact@v4
if: github.event_name == 'pull_request'
- name: Export PR comment data
if: ${{ github.event_name == 'pull_request' }}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Each step in pr-comment-data-export has this if already. Can we remove it either here or in the action?

Comment on lines 75 to 76
printf "C:\\msys64\\usr\\bin" >> "$GITHUB_PATH"
printf "C:\\msys64\\mingw64\\bin" >> "$GITHUB_PATH"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When should we be using printf over echo? Note that there is another echo below in this Windows step.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was because of a shellcheck warning. The double backslashes aren't handled the same way in echo in all bash'es apparently.

if: >
github.event.workflow_run.event == 'pull_request' &&
github.event.workflow_run.conclusion == 'failure'
if: github.event.workflow_run.event == 'pull_request'
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the case of qns, the comment should still only be printed on failure, right?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this needs to be restored - I was just trying to make it generate any output.

@larseggert larseggert marked this pull request as ready for review March 11, 2024 16:17
@larseggert larseggert merged commit 532dcc5 into mozilla:main Mar 11, 2024
11 of 12 checks passed
@larseggert larseggert deleted the ci-bench-comment branch March 11, 2024 16:17
@larseggert
Copy link
Collaborator Author

Merged, since can't really test this as a PR. Will continue on main.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants