Dear Support,

We are having issues at importing xml (or zip containing a set or xml file) just exported using Collect Earth.

Here is the log of the error: ERROR 2014-11-18 14:52:55,148 [XML Import Thread 3.xml] org.openforis.collect.io.data.XMLDataImportProcess: error in opening zip file java.util.zip.ZipException: error in opening zip file at java.util.zip.ZipFile.open(Native Method) at java.util.zip.ZipFile.<init>(Unknown Source) at java.util.zip.ZipFile.<init>(Unknown Source) at java.util.zip.ZipFile.<init>(Unknown Source) at org.openforis.collect.io.data.XMLDataImportProcess.extractPackagedSurvey(XMLDataImportProcess.java:518) at org.openforis.collect.io.data.XMLDataImportProcess.createDataImportSummary(XMLDataImportProcess.java:152) at org.openforis.collect.io.data.XMLDataImportProcess.call(XMLDataImportProcess.java:136) at org.openforis.collect.earth.app.view.ImportXMLDialogProcessMonitor.startImport(ImportXMLDialogProcessMonitor.java:80) at org.openforis.collect.earth.app.view.ImportActionListener$1.run(ImportActionListener.java:76) ERROR 2014-11-18 14:52:55,149 [XML Import Thread 1.xml] org.openforis.collect.io.data.XMLDataImportProcess: error in opening zip file java.util.zip.ZipException: error in opening zip file at java.util.zip.ZipFile.open(Native Method) at java.util.zip.ZipFile.<init>(Unknown Source) at java.util.zip.ZipFile.<init>(Unknown Source) at java.util.zip.ZipFile.<init>(Unknown Source) at org.openforis.collect.io.data.XMLDataImportProcess.extractPackagedSurvey(XMLDataImportProcess.java:518) at org.openforis.collect.io.data.XMLDataImportProcess.createDataImportSummary(XMLDataImportProcess.java:152) at org.openforis.collect.io.data.XMLDataImportProcess.call(XMLDataImportProcess.java:136) at org.openforis.collect.earth.app.view.ImportXMLDialogProcessMonitor.startImport(ImportXMLDialogProcessMonitor.java:80) at org.openforis.collect.earth.app.view.ImportActionListener$1.run(ImportActionListener.java:76) ERROR 2014-11-18 14:54:06,996 [XML Import Thread 1.xml] org.openforis.collect.io.data.XMLDataImportProcess: error in opening zip file java.util.zip.ZipException: error in opening zip file at java.util.zip.ZipFile.open(Native Method) at java.util.zip.ZipFile.<init>(Unknown Source) at java.util.zip.ZipFile.<init>(Unknown Source) at java.util.zip.ZipFile.<init>(Unknown Source) at org.openforis.collect.io.data.XMLDataImportProcess.extractPackagedSurvey(XMLDataImportProcess.java:518) at org.openforis.collect.io.data.XMLDataImportProcess.createDataImportSummary(XMLDataImportProcess.java:152) at org.openforis.collect.io.data.XMLDataImportProcess.call(XMLDataImportProcess.java:136) at org.openforis.collect.earth.app.view.ImportXMLDialogProcessMonitor.startImport(ImportXMLDialogProcessMonitor.java:80) at org.openforis.collect.earth.app.view.ImportActionListener$1.run(ImportActionListener.java:76)

Can you please advise?

Cheers, Alessio

asked 18 Nov '14, 03:05

alessioalfonsetti's gravatar image

alessioalfon...
11445
accept rate: 0%


So from further contact with this user:

The file he was trying to import looked like this when opened in WinRAR :

alt text

This means that the file he is trying to import is not the file generated though Collect Earth!

The file generated by Collect Earth should have this structure:

alt text

Where idm.xml is the survey definition and the folder 1 contains all of the plot information (there is an XML file per plot), which is in fact the contents of the first file shown ( the xmlfilelist 1,2,3,4 and so on )

So the easy solution here are:

  1. Export the data collected again and this time DO NOT TINKER with the data
  2. In your Collect Earth export the data to XML and then just copy the contents from the first "corrupted"file into the folder "1" of this newly created ZIP file (you can basically just move the files from on file to the other )

So now you have a file that is following the structure that Collect Earth expects and that should work fine!!

permanent link

answered 18 Nov '14, 10:16

Open%20Foris's gravatar image

Open Foris ♦♦
9995714
accept rate: 10%

Hello there,

Thanks for the fast reply. Unfortunately the zip file is valid and the compression tools are able to work with it successful. As I said the issue also happens if we try to upload on by one (or a set of) the xml files originally compressed on to the zip file. No permission issues are detected on the log file and the import has been also tested with a faoadmin user on a FAO machine (just to make sure to have full capabilities on the file system).

Finally no problems detected on exporting.

Cheers, Alessio

permanent link

answered 18 Nov '14, 09:49

alessioalfonsetti's gravatar image

alessioalfon...
11445
accept rate: 0%

Hello Alessio,

This looks like a ZIP file corruption/error.

Can the ZIP file be open normally with WinRAR, WinZip or similar software?

Could there be a permission issue?

Was there any problem when you exported the data to XML ( ZIP file ) using Collect earth ?

/Collect Earth support

permanent link

answered 18 Nov '14, 09:19

collectearth's gravatar image

collectearth ♦
1.0k16
accept rate: 17%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×281

question asked: 18 Nov '14, 03:05

question was seen: 7,612 times

last updated: 18 Nov '14, 10:16