I am trying to update radio button fields in JIRA using python logic by building a dictionary. After I built the dictionary, when I try to create issue in JIRA, I am getting an error message -
<span>'customfield_10543'</span>: <span>"Option id 'null' is not valid"</span>}
Python logic:
options = [<span>'10461'</span>,<span>'10462'</span>]
new_issues = []
new_issue = {
<span>'project'</span>: {<span>"key"</span>:<span>"Test"</span>},
<span>'summary'</span>: <span>'Test Summary'</span>,
<span>'description'</span>: <span>'Test issue by Jira Integration'</span>
)
<span>if</span> df.having_pet.iloc[i] == <span>'YES'</span>:
new_issue[having_pet] = {<span>'value'</span>:options[<span>0</span>]}
<span>if</span> df.having_pet.iloc[i] == <span>'NO'</span>:
new_issue[having_pet] = {<span>'value'</span>:options[<span>1</span>]}
new_issues.append(new_issue)
jira.create_issues(field_list=new_issues)
HTML component from Chrome Inspector:
<<span>input</span> <span>class="radio" id="customfield_10543-1" name="customfield_10543" type="radio" value="10461" resolved="">
<label for="customfield_10543-1">
Yes
</label>
<input checked="checked" class="radio" id="customfield_10543-2" name="customfield_10543" type="radio" value="10462" resolved="">
<label for="customfield_10543-2">
No
</label></span>
Please advise how to update the radio button on JIRA based on dataframe that i have.