Uploaded image for project: 'Jira Data Center'
  1. Jira Data Center
  2. JRASERVER-66518

JIRA Status is reported as "No associated workflows" while it's still used

    XMLWordPrintable

Details

    Description

      Summary

      JIRA Status at Statuses page shows "No associated workflows", if you tried to Delete the status, you will get following error: Given status is currently associated with a workflow(s) and cannot be deleted .
      It's not clear if status is used or not. In this case status is used, but Statuses page shows incorrect data.

      Steps to Reproduce

      1. Create status status1 and associate with workflow Workflow1
      2. Edit workflow_Workflow1_ and remove status status1
        • Normally this is not possible as JIRA would not allow removing statuses from active workflow
      3. Don't safe the Workflow1 and keep the draft
      4. Navigate to [ Admin > Issues > Statuses ]
      5. Check status for status1

      Expected Results

      Status has 1 associated workflow

      Actual Results

      No associated workflows

      Notes

      • If you proceed with Delete, you will get following error: Given status is currently associated with a workflow(s) and cannot be deleted
      • The problem is caused by chain of factors
        1. Initial Workflow1 had status1
        2. Workflow1 was edited and draft was not saved
        3. The draft workflow doesn't have status1
        4. During computation of workflows for statuses draft workflow is used, so JIRA couldn't detect the status.

      Workaround

      To fix the problem, please follow the steps below:

      1. Check status in workflows tables running the SQL query below:
        select id,workflowname from jiraworkflows where descriptor like '%status1%';
        select parentname from jiradraftworkflows where descriptor like '%status1%';
        
        • Take note on the workflow name from the output.
      2. Go to the workflow page and edit the workflow.
      3. Discard or publish the draft workflow and then we will see the status associated with the workflow.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ayakovlev@atlassian.com Andriy Yakovlev [Atlassian]
              Votes:
              34 Vote for this issue
              Watchers:
              21 Start watching this issue

              Dates

                Created:
                Updated: