Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Need to get issuelinks types with Jira python

stew john
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 17, 2019

Hi,

I am writing a script with Jira python and I have encountered a big obstacle here.

I need to access to one of the issuelinks under "is duplicated by" but I don't have any idea about the attributes I can use.

I can get to the issuelinks field but I can't go further from here.

This is I've got so far:

 

issue = jira.issue(ISSUE_NUM) #this is the issue I am handling

link = issue.fields.issuelinks # I 've accessed to the issuelinks field

if hasattr(link, "inwardIssue"):

    inwardIssue = link.inwardIssue

 

and I want to do this from here :

if(str(inwardIssue.type(?)) == "is duplicated by"):

~~~~~

 

inward Issues can be 

- is cloned by

- is duplicated by 

and so on.

 

how can I get the type of inward Issues??

2 answers

0 votes
Jay Wang
Contributor
July 26, 2022

link.type works for me

0 votes
Dale Ehrhardt
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
April 18, 2019

use link.type.inward to get the link type info you are looking for

Suggest an answer

Log in or Sign up to answer