-
Notifications
You must be signed in to change notification settings - Fork 66
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
HTTP Error 422: Unprocessable Entity
returned for issues.add_labels
in version 0.1.17
#69
Comments
Same problem. Looks like PR below removed "labels" parameter. |
Hi team, we met the same problem when using the API |
Hi team, we met the same issue when calling another API. Could you help take a look? Thanks!
|
I'll take a look within next week or so |
This is something I tried to debug, but it isn't a quick fix (or at least something I wasn't able to fix). I shared everything I could with @jph00, perhaps he might be able to help with this one. I suspect many of the open issues in this repo could be correlated. |
Thanks for your investigation, Hamel! I hope @jph00 could help on this issue. |
I've looked at this one and it's working fine in our tests. You can see a working example in the definition in the lib of |
I just tried calling that endpoint and it worked for me. Maybe you're using the wrong id? Note that you can use an email address instead, if you use the 'email' param. |
@jhlegarreta @roy-ht I've just cut a release which resolves the (The issue was due to a change in the OpenAPI spec to use OpenAPI functionality that previously wasn't used, so wasn't handled by ghapi.) |
@jph00 thanks for the effort and sorry for the delay in updating. I've tested the 0.1.18 release as the minimum version fixing the issue and it did work successfully, and hence the patch set fixed the issue: Thanks 💯 !! |
I'm having issues with the
ghapi 0.1.17
version released on May, 24th.I have a private project where I use
ghapi
to automatically label PRs and issues based on the path of the files mentioned or modified, and the title of the PR/issue. I am using the following public project to test the workflows and scripts:https://github.com/jhlegarreta/labelertest
The labeler on the PR/issue title was working fine with
ghapi 0.1.16
, but it is systematically returning anHTTP Error 422: Unprocessable Entity
error for the following call:where the
issue_number
andlabels
have the appropriate values.Here is an example of a successful call using
0.1.16
:https://github.com/jhlegarreta/labelertest/runs/2750092407?check_suite_focus=true#step:5:495
And here is an example of a successful call using
0.1.17
:https://github.com/jhlegarreta/labelertest/runs/2750038846?check_suite_focus=true#step:5:505
for the same contents from the viewpoint of the files added in the PRs and their titles.
I have not found any release notes notifying about changes, or an older version of the documentation. According to the latest documentation:
https://docs.github.com/en/rest/reference/issues#add-labels-to-an-issue
I would be providing the expected parameters to the call.
For what is worth, the
0.1.16
was also working when I only had:but
0.1.17
failed as described, so the parameters seem not to be the problem.The relevant GitHub workflow file is https://github.com/jhlegarreta/labelertest/blob/main/.github/workflows/pr_title_labeler.yml, and the Python script containing the calls to the
ghapi
is https://github.com/jhlegarreta/labelertest/blob/main/.github/scripts/pr_title_regex_labeler.pyWould you please be able to tell what I am doing wrong.
Thanks for providing us with this valuable tool and thanks for the support.
The text was updated successfully, but these errors were encountered: