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: fix/refactor labeler workflow #3921

Merged
merged 2 commits into from
Mar 19, 2024

Conversation

trentm
Copy link
Member

@trentm trentm commented Mar 19, 2024

  • use more reliable 'elastic' org membership test for triage, etc. labels
  • bypass 'action-add-labels' action to avoid another dep
  • drop agent-nodejs label that we no longer require for use in GH projects

Fixes: #3884


The actions/github-script@v7 usage is from apm-agent-java.
The dropping agent-nodejs label adding is pending on team discussion (https://elastic.slack.com/archives/C9A6ANR5Y/p1710809441508399).

- use more reliable 'elastic' org membership test for triage, etc. labels
- bypass 'action-add-labels' action to avoid another dep
@trentm trentm self-assigned this Mar 19, 2024

- name: Add community and triage labels
if: steps.checkUserMember.outputs.isTeamMember != 'true' && steps.checkUserMember.outputs.isExcluded != 'true'
uses: actions-ecosystem/action-add-labels@v1
if: contains(steps.is_elastic_member.outputs.result, 'false') && github.actor != 'dependabot[bot]'
Copy link
Member

Choose a reason for hiding this comment

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

Did you omit @apmmachine for a reason?

Copy link
Member Author

@trentm trentm Mar 19, 2024

Choose a reason for hiding this comment

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

I am copying what apm-agent-java is doing, e.g.: https://github.com/elastic/apm-agent-java/blob/main/.github/workflows/labeler.yml#L33

Do we use apmmachine for creating issues or PRs? I don't see any: https://github.com/elastic/apm-agent-nodejs/issues?q=author%3A%40apmmachine+

Copy link
Member

Choose a reason for hiding this comment

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

We are still using it for updatecli workflows.

I think you need to remove the @ in the search.

https://github.com/elastic/apm-agent-nodejs/issues?q=author%3Aapmmachine+ shows the last PR in january.

Copy link
Member Author

@trentm trentm Mar 19, 2024

Choose a reason for hiding this comment

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

Thanks.

Presumably apm-agent-java will have the same issue, then.

Copy link
Member Author

Choose a reason for hiding this comment

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

@reakaleek Oh, actually, @apmmachine is a member of "elastic", so we don't need to explicitly handle excluding github.actor === 'apmmachine' in this test.

Copy link
Member

Choose a reason for hiding this comment

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

Ah, right. Makes sense.

@trentm trentm merged commit 41c8dcf into main Mar 19, 2024
27 checks passed
@trentm trentm deleted the trentm/fix-labeler-action-final-really-use-this-one branch March 19, 2024 16:09
fpm-peter pushed a commit to fpm-git/apm-agent-nodejs that referenced this pull request Aug 20, 2024
- use more reliable 'elastic' org membership test for triage, etc. labels
- bypass 'action-add-labels' action to avoid another dep
- drop agent-nodejs label that we no longer require for use in GH projects

Fixes: elastic#3884
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.

issue labeler workflow failing
2 participants