go-jira icon indicating copy to clipboard operation
go-jira copied to clipboard

`IssueFields.Unknowns` and `IssueFields.Names` not returned in `Issue.SearchWithContext` api

Open karanpopat opened this issue 1 year ago • 1 comments

What happened?

The fields IssueFields.Unknowns and IssueFields.Names are not being returned in Issue.SearchWithContext API, while its coming in the Issue.Get API. We are setting Expand: "names" in the SearchOptions

What did you expect to happen?

The fields IssueFields.Unknowns and IssueFields.Names return the information in the Search API.

How can we reproduce it (as minimally and precisely as possible)?

options := jira.SearchOptions{
	StartAt:    0,
	MaxResults: limit,
	Expand:     "names",
}

issues, res, err := client.Issue.SearchWithContext(ctx, jql, &options)

Your Environment

  • go-jira version (git tag or sha): 1.16.0
  • Go version (go version): go version go1.20.3 darwin/arm64
  • Jira type (cloud or on-premise): cloud
  • Jira version / Api version:

karanpopat avatar Jun 12 '23 16:06 karanpopat

Thanks @karanpopat for the bug report. I am currently short on time for open-source contributions due to other/private obligations. If you are able to fix it, I am happy to review a pull request. Thanks for contributing to open source (also via this issue!) and thanks for understanding.

andygrunwald avatar Jun 14 '23 05:06 andygrunwald