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

appendOnly: true doesn't seem to work #104

Closed
jrfnl opened this issue Nov 9, 2023 · 4 comments · Fixed by #111
Closed

appendOnly: true doesn't seem to work #104

jrfnl opened this issue Nov 9, 2023 · 4 comments · Fixed by #111
Assignees
Labels
bug Something isn't working

Comments

@jrfnl
Copy link

jrfnl commented Nov 9, 2023

I'm experimenting with this action at the moment and noticed the following:

Given a labeler.yml file containing the following:

version: 1
appendOnly: true
labels:
- label: "Status: triage"
  draft: False
  author-can-merge: False
- label: "Type: bug"
  draft: False
  body: ".* bug .*"
- label: "Type: documentation"
  draft: False
  files:
  - "/Docs/[A-Za-z0-9-]*/.*Standard.xml$"

This happens:

When a new PR is opened and the Type: bug label is manually added, but the body of the PR does not contain the term "bug" (though the title does), the Type: bug label is removed from the PR by the workflow.

Same thing with the Type: documentation label. If this was manually added on creating the PR, the workflow removes it when the files regex doesn't match any files.

While I expected:

... the appendOnly: true setting to prevent this from happening.

Please let me know if you need more information and thank you for creating this action runner!

@srvaroa
Copy link
Owner

srvaroa commented Nov 9, 2023

Thanks for reporting it @jrfnl , I will look into this

@jrfnl
Copy link
Author

jrfnl commented Nov 9, 2023

@srvaroa Much appreciated!

@srvaroa srvaroa self-assigned this Nov 9, 2023
@srvaroa srvaroa added the bug Something isn't working label Nov 9, 2023
jrfnl added a commit to PHPCSStandards/PHP_CodeSniffer that referenced this issue Nov 10, 2023
... to prevent running into a bug which I've reported to the action runner: srvaroa/labeler#104

The default pull request template contain a categorization section anyway (which is not typically used for maintainer PRs), so let's use that section to auto-label the "Type" for new PRs.
jrfnl added a commit to PHPCSStandards/PHP_CodeSniffer that referenced this issue Nov 10, 2023
... to prevent running into a bug which I've reported to the action runner: srvaroa/labeler#104

The default pull request template contain a categorization section anyway (which is not typically used for maintainer PRs), so let's use that section to auto-label the "Type" for new PRs.
@srvaroa srvaroa linked a pull request Nov 11, 2023 that will close this issue
@srvaroa
Copy link
Owner

srvaroa commented Nov 11, 2023

@jrfnl this should be fixed as of v1.7.2 (or on the floating v1 if you're already on it).

@jrfnl
Copy link
Author

jrfnl commented Nov 11, 2023

Thank you @srvaroa ! I'm currently working on another workflow, once that's done, I'll switch this one to v1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants