ISA-tools / MAGEtoISAconverter

Converter which can pull from ArrayExpress (by an accession number) or read local files and convert them to ISAtab. Lead by Philippe Rocca-Serra & Eamonn Maguire, University of Oxford
http://isa-tools.org
7 stars 2 forks source link

IndexOutOfBounds Error #6

Closed psm3426 closed 11 years ago

psm3426 commented 12 years ago

Hello. I've been running the JAR file on my local machine to convert some ArrayExpress Experiments and many of them had errors. When I looked at the messages sent by the compiler, most of them were the result of an IndexOutOfBounds Exception.

Most of these were thrown by line 125 of MAGETabSDRFLoader.java: Column scanName = columnOrders.remove(Utils.getIndexForValue("Scan Name", columnOrders));

When looking at the files in question, basically the "Scan Name" header didn't exist, causing the error.

I also occasionally saw the exception thrown by line 126 of MAGETabSDRFLoader.java: columnOrders.add(derivedArrayDataFileIndex - 1, scanName);

This was thrown because derivedArrayDataFileIndex had a value of -1 because the "Derived Array Data File" header was missing.

Could this be fixed please?

SusannaSansone commented 12 years ago

fixed.

psm3426 commented 12 years ago

I just tried the (new?) JAR file (MAGETabtoISATab-0.2.jar), and on E-MTAB-888, I got an IndexOutOfBoundsException.

Here is the full trace:

http://www.ebi.ac.uk/arrayexpress/files/E-MTAB-888/E-MTAB-888.idf.txt Directory: E-MTAB-888 created Alternative Design Tag found at: Comment[AEExperimentType] ChIP-seq
protein-DNA binding site identification nucleotide sequencing protein-DNA binding site identification nucleotide sequencing http://www.ebi.ac.uk/arrayexpress/files/E-MTAB-888/E-MTAB-888.sdrf.txt java.lang.IndexOutOfBoundsException: Index: -2, Size: 22 at java.util.LinkedList.entry(LinkedList.java:365) at java.util.LinkedList.add(LinkedList.java:344) at org.isatools.magetoisatab.io.MAGETabSDRFLoader.loadsdrfTab(MAGETabSDRFLoader.java:126) at org.isatools.magetoisatab.io.MAGETabObtain.doConversion(MAGETabObtain.java:76) at org.isatools.magetoisatab.io.MAGETabObtain.main(MAGETabObtain.java:101)

I tried to look up the line numbers to figure out what was wrong, but the current code has changed, so the line numbers no longer match.

proccaserra commented 12 years ago

Hi Psalm, The commit did not close the issue. there are still many cases which break the converter, I am nearly done though. I am currently post processing converting files to clean up the many issues I have to deal with with dodgy MAGE-TAB file currently served. I hope to commit sometime next week and close the issue.

Best

psm3426 commented 12 years ago

That's great! Thank you! =D

psm3426 commented 12 years ago

Has the JAR in the downloads section been updated?

eamonnmag commented 12 years ago

Updated now. Sorry, only seeing this comment now. We have one issue with column order to sort for the 0.3 release.