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

Enhancement: detect manual labeling #13

Open
thaJeztah opened this issue Nov 8, 2016 · 3 comments
Open

Enhancement: detect manual labeling #13

thaJeztah opened this issue Nov 8, 2016 · 3 comments

Comments

@thaJeztah
Copy link
Contributor

Per discussion on moby/moby#28143 (comment), we should have a way to detect if labels on an issue were manually corrected. This may be a difficult one, but initial thoughts;

  • add a label "manual-override" (e.g.) that tells poule to not apply labels
  • detect if the issue/PR has a "person X removed label xyz" action, and if so, don't re-apply that label (may be expensive)
  • detect if labels of a specific kind are already present (e.g., if a "area/xyz" label is already present, don't add a different area, likewise for "kind/xyz")
  • other suggestions?

/cc @icecrime @ehazlett

@ehazlett
Copy link
Collaborator

ehazlett commented Nov 8, 2016

those all sound reasonable to me

@icecrime
Copy link
Owner

icecrime commented Nov 8, 2016

Just one small note: as it is configured today in Docker, poule will only add labels when an issue is initially opened, reopened, or edited. Unless one of those events apply, we can manually change them and they will state.

add a label "manual-override" (e.g.) that tells poule to not apply labels

Easy enough.

detect if the issue/PR has a "person X removed label xyz" action, and if so, don't re-apply that label (may be expensive)

I don't think that's doable through GitHub's API (there's no audit trail of who did what).

detect if labels of a specific kind are already present (e.g., if a "area/xyz" label is already present, don't add a different area, likewise for "kind/xyz")

I merged something in this morning that allows just that! I added the support for filtering in serve mode, so we should be able to do things like:

- triggers:
      pull_request: [ opened ]
  operations:
      - type:       label
        filters:     {
            ~labels: [ "status/1-design-review", "status/2-code-review", "status/3-docs-review" ],
        settings: {
            patterns: {
                status/0-triage:     [ ".*" ],
            }
        }

@thaJeztah
Copy link
Contributor Author

Sounds good already @icecrime! I suggest to monitor how it works out, and see if we need changes or not. If it works fine, I'll close this issue

Great work!

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

No branches or pull requests

3 participants