rust-lang / triagebot

Automation/tooling for Rust spaces
https://triage.rust-lang.org
Apache License 2.0
170 stars 75 forks source link

"Label X can only be set by Rust team members" when label doesn't exist #1721

Open tgross35 opened 10 months ago

tgross35 commented 10 months ago

It seems like trying to label something if it doesn't exist gives an insufficient permissions error, rather than some sort of "label not found" error which would make more sense. Example:

https://github.com/rust-lang/rust/pull/115719#issuecomment-1712592345

Also from that example, maybe labels should be checked case insensitive

ehuss commented 10 months ago

I think the issue there is just the case-sensitivity check for permissions. Generally, GitHub is case-insensitive for labels, but the triagebot code here is not. I believe glob supports case-insensitive matching, and a PR to update that would be welcome.

tgross35 commented 10 months ago

Thanks, I made the matching case insensistive in #1722. I still think the message could be improved - even if someone does @rustbot label +definitely-doesnt-exist it should say that the label doesn't exist rather than that permissions aren't sufficient