-
Notifications
You must be signed in to change notification settings - Fork 69
Calls to search.issuesAndPullRequests are dropping the "q" parameter #114
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
Comments
Thank you for the thorough bug report! However, I cannot reproduce the problem: We didn't have any release of an Does the problem persist for you? If so, could you please create a test repository with a lock file that reliably reproduces the problem you reported? |
I've contacted GitHub support about this, my guess is there was a temporary problem with the API. We have seen reports of @semantic-release builds that suddenly failed with error messages such as this The error
makes no sense to me, because response URL includes the
so does the url in the parsed request options
|
Mystery solved, please update your lock files, make sure you don't have |
Yep, confirmed...
All works fine |
Checklist
Environment
Versions
What happened?
I recently updated my Node dependencies and calls to
octokit.rest.search.issuesAndPullRequests
have stopped working and now report an error containing{"message":"Validation Failed","errors":[{"resource":"Search","field":"q","code":"missing"}
Minimal test case to reproduce the problem
I've installed
octokit/rest
fresh today. When I run this snippet below...I get the error below:
The error is claiming that the
q
parameter is missing, but it is specified in the code and is echoed in the error. I find the same behaviour when talking to an enterprise instance with a personal access token.If I make the equivalent
curl
call (i.e.curl "https://api.github.com/search/issues?q=properties+is%3Aissue+repo%3A%22octokit%2Frest%22+label%3Abug"
) then I get the error below...... which is what I'd expect (there is a
q
value, but I'm not allowed to see the results).If I change my snippet code such that
const octokit = new Octokit({ baseUrl: 'http://localhost:12345' })
and havenetcat
listening on 12345 then I see the following request come in...... so the endpoint isn't wrong; the
q
parameter is not being added to the request URL any moreWhat did you expect to happen?
Calls to
octokit.rest.search.issuesAndPullRequests({ q })
would return a list of issues (or at least include theq
parameter in the outgoing call)What the problem might be
Other than it's a change made since about June somewhere in one of the octokit dependencies, I've not yet found where the parameter is being dropped
The text was updated successfully, but these errors were encountered: