beer9
asked on
Using JIRA module how to move a issue as subtask in Python
I am using below code:
But when I run it as
Though I am providing the parent key, I would like to know how to fix it?
from jira import JIRA
import sys
options = {'server': 'https://jira.com', 'verify': False}
jira = JIRA(options, basic_auth=('user@example.com', 'Password123'))
child_key = sys.argv[1]
parent_key = sys.argv[2]
issue = jira.issue(child_key)
update_issue = issue.update(issuetype={'name': 'Sub Task'}, parent={'key': parent_key})
But when I run it as
python mycode.py PROJECT-123 PROJECT-100
then I get the below error:Issue type is a sub-task but parent issue key or id not specified.
Though I am providing the parent key, I would like to know how to fix it?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER