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

Importing issues via CSV does not create issue links

XMLWordPrintable

    • 1
    • 11
    • We collect Jira feedback from various sources, and we evaluate what we've collected when planning our product roadmap. To understand how this piece of feedback will be reviewed, see our Implementation of New Features Policy.

      Problem Definition

      When importing Jira issues via CSV, links are not imported with the following error being shown. 

      Unable to link issue from 10112 to MIN-17 with link named 'Blocks': Cannot find imported issue key for external id 'MIN-17'

      Steps to Reproduce

      1. Create a CSV of Jira issues that contain issue links
      2. Import the CSV 
      3. Jira will fail to import the issue links due to the issue ids being changed.

      Example of logging:

      # First step is importing the issues 
      
      2020-02-28 16:43:24,372 INFO - Importing: Issues
      2020-02-28 16:43:24,372 INFO - ------------------------------
      2020-02-28 16:43:24,372 INFO - Only new items will be imported
      2020-02-28 16:43:24,388 INFO - Importing issue: [externalId='10116', summary='Instructions for deleting this sample board and project are in the description for this issue >> Click the "MIN-17" link and read the description tab of the detail view for more']
      2020-02-28 16:43:24,436 INFO - Custom field not found. Creating a new custom field for com.atlassian.jira.plugins.importer.external.beans.ExternalCustomField@6598bcf6[id=External issue ID,name=External issue ID,typeKey=com.atlassian.jira.plugin.system.customfieldtypes:textfield,searcherKey=com.atlassian.jira.plugin.system.customfieldtypes:textsearcher,valueMappingDefinition=<null>,valueSet=<null>]
      2020-02-28 16:43:24,684 INFO - Importing issue: [externalId='10112', summary='As a developer, I can update details on an item using the Detail View >> Click the "MIN-13" link at the top of this card to open the detail view']
      2020-02-28 16:43:24,751 INFO - Reindexing last 2 issues imported ...
      2020-02-28 16:43:24,781 INFO - Reindexing took 27 ms.
      2020-02-28 16:43:24,781 INFO - 2 issues successfully created
      2020-02-28 16:43:24,781 INFO - ------------------------------
      2020-02-28 16:43:24,781 INFO - Finished Importing : Issues
      2020-02-28 16:43:24,781 INFO - ------------------------------
      
      # Now the system tries to import the links and fails because the Issue ID was changed
      2020-02-28 16:43:24,807 INFO - Importing: Issue Links & Subtasks
      2020-02-28 16:43:24,807 INFO - ------------------------------
      2020-02-28 16:43:24,807 INFO - Only new items will be imported
      2020-02-28 16:43:24,811 ERROR - Unable to link issue from 10112 to MIN-17 with link named 'Blocks': Cannot find imported issue key for external id 'MIN-17'
      2020-02-28 16:43:24,811 INFO - ------------------------------
      2020-02-28 16:43:24,811 INFO - Finished Importing : Issue Links & Subtasks
      2020-02-28 16:43:24,811 INFO - ------------------------------

      Suggested Solution

      During Import the system should be able to decipher that the Issue Keys are changed first and then the issue inks are imported. 

      Workaround

      When Jira imports issues into an empty project, it retains the numbering scheme of the Issue Key. 

      • Thusly, [OLD Project key]-337 becomes [NEW Project KEY]-337. 
      • To resolve this, find and replace in the CSV and change OLD PROJECT KEY to NEW PROJECT KEY and reimported the CSV.
      • When reimporting Jira knows issues exist and do not need to be recreated/doubled. 
      • During the linking, as Jira could now find the Issue Key it could link the issues successfully. 

              Unassigned Unassigned
              clevine Chris Levine
              Votes:
              4 Vote for this issue
              Watchers:
              7 Start watching this issue

                Created:
                Updated: