CSV import dialog doesn't handle csv errors gracefully
------------------------------------------------------
Key: DS-834
URL: https://jira.duraspace.org/browse/DS-834
Project: DSpace
Issue Type: Bug
Components: XMLUI
Affects Versions: 1.6.2
Reporter: Timo Aalto
I was trying to upload a csv containing some metadata changes. In the upload
dialog I all got was "no changes were detected" splash. It turned out that I
had accidentally left some completely empty columns in the middle of the CSV
file. Luckily I had a ssh screen running and it showed the stack trace below.
It would be good to catch that exception and provide some guidance for the poor
dspace admin trying to figure out what went wrong.
java.lang.ArrayIndexOutOfBoundsException: 1
at
org.dspace.app.bulkedit.MetadataImport.compare(MetadataImport.java:345)
at
org.dspace.app.bulkedit.MetadataImport.runImport(MetadataImport.java:154)
at
org.dspace.app.xmlui.aspect.administrative.FlowMetadataImportUtils.processUploadCSV(FlowMetadataImportUtils.java:178)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:155)
at
org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:243)
at
org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:3237)
at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:2394)
at
org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:162)
at
org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:393)
at
org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:2834)
at
org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:160)
at org.mozilla.javascript.Context.call(Context.java:538)
at
org.mozilla.javascript.ScriptableObject.callMethod(ScriptableObject.java:1833)
at
org.mozilla.javascript.ScriptableObject.callMethod(ScriptableObject.java:1803)
at
org.apache.cocoon.components.flow.javascript.fom.FOM_JavaScriptInterpreter.handleContinuation(FOM_JavaScriptInterpreter.java:698)
at
org.apache.cocoon.components.treeprocessor.sitemap.CallFunctionNode.invoke(CallFunctionNode.java:94)
at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:55)
at
org.apache.cocoon.components.treeprocessor.sitemap.MatchNode.invoke(MatchNode.java:87)
at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:55)
at
org.apache.cocoon.components.treeprocessor.sitemap.MatchNode.invoke(MatchNode.java:87)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.duraspace.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
------------------------------------------------------------------------------
Free Software Download: Index, Search & Analyze Logs and other IT data in
Real-Time with Splunk. Collect, index and harness all the fast moving IT data
generated by your applications, servers and devices whether physical, virtual
or in the cloud. Deliver compliance at lower cost and gain new business
insights. http://p.sf.net/sfu/splunk-dev2dev
_______________________________________________
Dspace-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-devel