Forums

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

CSV Issue imports encounter "Fatal error during import" w/ validator

JC
May 8, 2016

We need to import ~500-2000 issues daily from a legacy ticketing system. Many will be duplicates. We created a validator to locate the duplicates (based off their unique summary) and prevent their creation. The import is performed by end-users on our team, using the issue -> 'import from csv' link

We see a "Fatal error during import" everytime we use the validator

2016-05-05 07:51:29,439 INFO - Importer started!
2016-05-05 07:51:29,440 INFO - Engine is running in Import mode
2016-05-05 07:51:29,450 INFO - All issues will be imported to project: TestProject (TEST)
2016-05-05 07:51:29,454 INFO - Creating issue: ExternalIssue
{externalId=autoid-4493924815619197614, summary=CM1, issueType=CM Unknown Subtask}
2016-05-05 07:51:29,693 ERROR - Fatal error during import
java.lang.NullPointerException
at com.atlassian.jira.config.DefaultSubTaskManager.createSubTaskIssueLink(DefaultSubTaskManager.java:582)
at sun.reflect.GeneratedMethodAccessor2522.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at com.atlassian.plugin.osgi.hostcomponents.impl.DefaultComponentRegistrar$ContextClassLoaderSettingInvocationHandler.invoke(DefaultComponentRegistrar.java:134)
at com.sun.proxy.$Proxy484.createSubTaskIssueLink(Unknown Source)
at sun.reflect.GeneratedMethodAccessor2522.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307)
at org.springframework.osgi.service.importer.support.internal.aop.ServiceInvoker.doInvoke(ServiceInvoker.java:58)
at org.springframework.osgi.service.importer.support.internal.aop.ServiceInvoker.invoke(ServiceInvoker.java:62)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.osgi.service.util.internal.aop.ServiceTCCLInterceptor.invokeUnprivileged(ServiceTCCLInterceptor.java:56)
at org.springframework.osgi.service.util.internal.aop.ServiceTCCLInterceptor.invoke(ServiceTCCLInterceptor.java:39)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.osgi.service.importer.support.LocalBundleContextAdvice.invoke(LocalBundleContextAdvice.java:59)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at com.sun.proxy.$Proxy4201.createSubTaskIssueLink(Unknown Source)
at com.atlassian.jira.plugins.importer.imports.importer.impl.CompatibilityUtil.createSubTaskIssueLink(CompatibilityUtil.java:137)
at com.atlassian.jira.plugins.importer.compatibility.CompatibilityBridgeUtils.createSubTaskIssueLink(CompatibilityBridgeUtils.java:172)
at com.atlassian.jira.plugins.importer.imports.bulkcreate.engine.BulkCreateDataImporter.createSubTaskLink(BulkCreateDataImporter.java:326)
at com.atlassian.jira.plugins.importer.imports.bulkcreate.engine.BulkCreateDataImporter.doImportSubtasks(BulkCreateDataImporter.java:298)
at com.atlassian.jira.plugins.importer.imports.bulkcreate.engine.BulkCreateDataImporter.runImporterEngine(BulkCreateDataImporter.java:175)
at com.atlassian.jira.plugins.importer.imports.bulkcreate.engine.BulkCreateDataImporter.doImport(BulkCreateDataImporter.java:148)
at com.atlassian.jira.plugins.importer.imports.importer.impl.ImporterCallable.call(ImporterCallable.java:26)
at com.atlassian.jira.plugins.importer.imports.importer.impl.ImporterCallable.call(ImporterCallable.java:15)
at com.atlassian.jira.task.TaskManagerImpl$TaskCallableDecorator.call(TaskManagerImpl.java:528)
at com.atlassian.jira.task.TaskManagerImpl$TaskCallableDecorator.call(TaskManagerImpl.java:491)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at com.atlassian.jira.task.ForkedThreadExecutor$ForkedRunnableDecorator.run(ForkedThreadExecutor.java:254)
at java.lang.Thread.run(Thread.java:745)

It doesn't matter if its a subtask, or a new issue its always resulted in the issue.

The validator looks like this,

the validator is a "Validation based on JQL query"
JQL Query:

project = "Project Name" AND summary ~ "%{00000}"


Condition: number of issues returned by the JQL query satisfies a boolean expression, with "Ephemeral number 1" (code

{00058}) storing the number of returned issues
Boolean expression:

{00058} = 0

 

Anybody have any ideas on how we can use this to prevent duplicates without it error out? Ive tried this as an administrator and it throws the same errors as well. We have attempted to import with a clean CSV file thats two lines long to ensure its not related to bad CSV data - and we always face the same issue. 

Thanks! 

3 answers

1 vote
Alex Reed
November 15, 2018

I found a plugin that might fix your problem. It helps to populate description and other text fields in jira issues - https://marketplace.atlassian.com/apps/1219597/field-templates-for-jira?hosting=server&tab=overview

0 votes
Ta Minh Thuy
May 20, 2021

Hi guys,

No need to use add-on in this case. All you need is creating a custom field name with the same name, Description and in the Field configuration, you render the field to make it wiki :)

It will looks exactly the system field Description :) From this newly created custom field, you can add template as you wish.

I did it!

0 votes
Nicolas Bourdages
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Champions.
August 10, 2015

Get the JEditor plugin. This adds an HTML renderer and allows you to pre-populate issues with an HTML template for text fields (description, comments or custom text fields). It also adds a toolbar, so formatting is easier.

Jirong Hu
Contributor
August 11, 2015

I create a template as follows to prepopulate the Description field, but the Description field is displaying this source code, not rendering. What should the template look like? h4. +Person responsible / On Call :+ {color:blue}<>{color} h4. +Problem Description :+ {color:blue}<>{color} h4. +Error Message :+ {color:blue}<>{color} h4. +Resolution :+ h6. Root Cause: {color:blue}<>{color} h6. Steps taken to resolve: {color:blue}<>{color} h6. Links : {color:blue}<>{color} h4. +Downstream Impact :+ {color:blue}<>{color}

Like Clément Dufour likes this
Nicolas Bourdages
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Champions.
August 11, 2015

Make sure that in your Field Configuration for this project / issue type, you selected the JEditor renderer. That will change the format of the field to HTML. The easiest way to make a template is to go backwards from that: Use the toolbars to build the template like you want, switch the field to HTML view (there's a tool for that in the toolbar) and use this HTML as your template.

Mary Slocum
October 17, 2018

Hello,

I have a template working in Jira v7.6.6 for my Description and it works fine with HTML. But, is there a way to not use HTML and keep it in plain text.

For example, my simple template is:

As a...

I need...

So that...

 

Thanks,

Mary

Suggest an answer

Log in or Sign up to answer