Skip to content
This repository has been archived by the owner on Jan 5, 2021. It is now read-only.

Jira Action List

milenk edited this page Jan 2, 2019 · 1 revision

First, make a jira filter that will serve as the action list itself, as described in Jira filter.

Than create the JiraActionList metric source:

JIRA_ACTION_LOG = metric_source.JiraActionList('https://jira.x.nl/jira',
    username="username", password="password", field_name='custom_due_date' )

optional argument field_name has the default of duedate, but because of controversial default access policy, this field is rarely used for the purpose. If you denoted a custom date field as the due date, set it here as the field_name.

Further, add the action log to the project:

PROJECT = Project(
    ...
    metric_sources={metric_source.ActionLog: JIRA_ACTION_LOG})

As last, add the jira filter id to the domain object that has the track actions requirement:

PROJECT = Project(
    ...
    metric_source_ids={ACTION_BOARD: '15221'})

Ignoring lists

Ignoring certain items from the filter is a bit more complicated, than for other action log lists. It is based on values of certain fields. For example, if one would like to exclude issues belonging to the epic certain epic IKS-144 and the epic itself, he would have to quote the custom filed name that holds the epic reference and the key itself, with the given value:

JIRA_ACTION_LOG = metric_source.JiraActionList('https://jira.x.nl/jira', username="username",
    password="password", field_name='custom_due_date', 
    lists_to_ignore=[{'customfield_10405': 'IKS-144'}, {'key': 'IKS-144'}])
Clone this wiki locally