-
Notifications
You must be signed in to change notification settings - Fork 51
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
UnhandledPromiseRejectionWarning: HttpError: Label does not exist
on issues where not all labels are to be applied
#32
Comments
It may be caused by calling Lines 79 to 82 in f40302d
The |
I use issue-labeler as the first of several steps in a GitHub action. If none of the conditions are met (meaning, the body contains none of the necessary keywords I'm looking for), then it throws this error. But because it doesn't fail the step, the following steps run anyway. My scenario is like this:
I would expect it to fail the step. However, I can also see when it might be preferable to ignore the case where no keywords are found. This seems like a need for a configuration, where it fails the step by default (by handling the error appropriately) but the action author could override that behavior (still catch the error but suppress it with a nice message in the logs). |
I'm trying out this action; it works but I get
UnhandledPromiseRejectionWarning
(s) while the action is running:It looks like it happens when not all labels are to be applied (i.e. most cases). Suppose I have the following label-matching definitions:
When an issue is filed with a body that contains both "test" and "bug", I don't see any warning. However, when the issue only contains either "test" or "bug", I see a warning. If the body contains neither, I see two warnings.
The text was updated successfully, but these errors were encountered: