Hi Community !
I'm trying to use the JIRA Rest API to update an Issue "Fix Version" to set it to a specific version. The current issue I update has some already created bad assignee ( the person assigned to it no more exist).
Using the normal Jira web interface, I am able to set the "Fix Version" to the desired value, even if the assignee is wrong.
Using the REST Issue PUT, I received an error : assignee: "User 'username' does not exist."
My REST call look like this (using chrome Advanced Rest Client and a C# implementation) :
Doing a PUT http://.../rest/api/2/issue/[issueId]/ Where [issueId] is the Id of my issue.
My payload is :
{
"update": {
"fixVersions" : [{"set":[{"name" : "Some Version"}]
}
]
}
}
1- Is it normal that I receive an error on the REST call while I can update the Issue from the web interface ?
2- Is there a way I can update this issue Fix Version by REST without changing the assignee ?
Thanks !
Community moderators have prevented the ability to post new answers.
Unfortuantely, you've fallen upon one of the oddities of the new inline editing. With REST we do issue validation, so all fields must be valid, the UI has inline editing, so only validates the field being edited. As you've guessed if you set the assignee correctly in the PUT, then it would be fine.
Thanks for your quick answer. Do you think of any workaround I could use ( by rest api ) to be able to update the issue anyway without changing the assignee ? I guess no workaround is possible, but I ask in case ;) If no workaround, I will manage/expect this 'possibility' of have validation error on other fields that the one I changed.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey,
I have a partially similar issue. I use a Python-REST-API implementation. There is no error regarding the username
But: adding or setting a fixVersion via API call actually deletes the exisiting fixVersion if there is any but does not set/add a new one, if there is none nothing happens.
The actions is shown in the log accordingly. As if the two verbs always result in deleting.
Any ideas?
Thanks in advance.
Ulf
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ulf,
I also need to add a new version to a previously populated fixVersion field, and like you I need to maintain existing versions already present in that field.
Can you do a get of the existing version string and then perform an add/set using the read version plus your new version.
Have you come across any solutions?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Peter
Sorry to say, no success. I tried a lot, but at last gave up. Just didn't work as expected. The documentation still says something about "work in progress"
https://developer.atlassian.com/display/JIRADEV/Updating+an+Issue+via+the+JIRA+REST+APIs
So I think waiting is an option...
Cheers,
Ulf
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.