Import project return error even though Jira has same custom field name

XMLWordPrintable

    • Type: Bug
    • Resolution: Unresolved
    • Priority: Low
    • None
    • Affects Version/s: 7.5.1, 7.13.0, 8.0.2
    • None
    • 7.05
    • 2
    • Severity 3 - Minor
    • 0

      Summary

      Import project return error even though Jira have same name custom field.

      Steps to Reproduce

      1. Install Jira with Japanese language
      2. Create new project A
      3. Install WBS Gantt-Chart for Jira
      4. Add value use the WBS Gantt-Chart
      5. Create backup XML
      6. Delete all issues, versions and components of project A
      7. Import XML to same instance

      Expected Results

      Import project succeed.

      Actual Results

      Return following error.

      2019-02-27 06:57:41,855 JiraTaskExectionThread-19 ERROR admin 417x3784x1 icuk9q 172.18.0.1 /secure/admin/ProjectImportSummary!reMapAndValidate.jspa [c.a.j.imports.project.DefaultProjectImportService] The custom field 'Finish date (WBSGantt)' of type '日付ピッカー' is required for the import but does not exist in the current JIRA instance.
      2019-02-27 06:57:41,855 JiraTaskExectionThread-19 ERROR admin 417x3784x1 icuk9q 172.18.0.1 /secure/admin/ProjectImportSummary!reMapAndValidate.jspa [c.a.j.imports.project.DefaultProjectImportService] The custom field 'Start date (WBSGantt)' of type '日付ピッカー' is required for the import but does not exist in the current JIRA instance.
      

      Workaround

      1. Unzip the exported XML
        $ unzip xxx.zip
        
      2. Confirmed the line in entities.xml which needs to be fixed
        $ grep -n '<english-custom-field-name>' entities.xml \
        | grep '<CustomField id='
        

        Please replace <english-custom-field-name> with the one you saw in the UI error

      3. Check the Japanese translation of the custom field
        $ grep '<english-custom-field-name>' entities.xml \
        | grep '<CustomField id=' \
        | cut -d '"' -f 2 \
        | xargs -I{} grep "jira.translation.custom.fieldcustomfield_{}.name.ja_JP" entities.xml \
        | cut -d '"' -f 2 \
        | xargs -I{} grep '<OSPropertyString id="{}"' entities.xml \
        | cut -d '"' -f 4
        

        Please replace <english-custom-field-name> with the one you saw in the UI error

      4. Replace row #2 name=xxxx to result of #3
      5. Recreate the XML
        $ zip xxx-fixed.zip activeobjects.xml entities.xml
        
      6. Import xxx-fixed.zip as usual

              Assignee:
              Unassigned
              Reporter:
              Tomoko Suzuki
              Votes:
              6 Vote for this issue
              Watchers:
              7 Start watching this issue

                Created:
                Updated: