Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to update JIRA issue reporter from Python

I'm trying to update the reporter of an issue using the JIRA Python API (version 1.0.3).

I am signed in (using basic auth) as a user who has full permissions, and I am trying to do it for an issue which I myself have created. The issue is successfully created, however when I call the update command, it changes the assignee rather than the reporter.

Any ideas? I have tried searching, but to no avail.

Here's my full code:

jira = JIRA('http://jiraurl.com/', basic_auth=('user', 'pass'))

new_issue = jira.create_issue(project='ER', summary='summary', description='desc', issuetype={'name': 'Custom Issue Type'})

new_issue.update(reporter='new_user')
like image 431
erik Avatar asked Oct 23 '25 18:10

erik


1 Answers

The right syntax should be new_issue.update(reporter={'name': 'new_user'})

The Jira documentation specify a similar example for the field assignee.

like image 71
Forge Avatar answered Oct 25 '25 06:10

Forge



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!