ArrayIndexOutOfBoundsException when creating mrv

User c23c5e9da4

15-06-2007 21:22:28

java.lang.ArrayIndexOutOfBoundsException: -1


at chemaxon.marvin.modules.SSSR.fillRingIdx(SSSR.java:1017)


at chemaxon.marvin.modules.SSSR.getRings(SSSR.java:396)


at chemaxon.marvin.modules.SSSR.callback(SSSR.java:1179)


at chemaxon.struc.CGraph.getSSSR(CGraph.java:1189)


at chemaxon.marvin.modules.Parity.initMolecule(Parity.java:1926)


at chemaxon.marvin.modules.Parity.modfunc(Parity.java:190)


at chemaxon.struc.MoleculeGraph.getParity(MoleculeGraph.java:1791)


at chemaxon.marvin.modules.CmlExport.areAtomParitiesWritten(CmlExport.java:375)


at chemaxon.marvin.modules.CmlExport.appendMoleculeGraph(CmlExport.java:348)


at chemaxon.marvin.modules.CmlExport.appendMolecule0(CmlExport.java:266)


at chemaxon.marvin.modules.CmlExport.appendReaction(CmlExport.java:219)


at chemaxon.marvin.modules.CmlExport.appendMolecule(CmlExport.java:169)


at chemaxon.marvin.modules.MrvExport.appendChemicalStruct(MrvExport.java:294)


at chemaxon.marvin.modules.MrvExport.convert0(MrvExport.java:95)


at chemaxon.marvin.modules.MrvExport.convert(MrvExport.java:71)


at chemaxon.struc.Molecule.exportToObject(Molecule.java:1324)


at chemaxon.struc.Molecule.exportToObject(Molecule.java:1289)


at chemaxon.struc.Molecule.exportToFormat(Molecule.java:1138)


at chemaxon.struc.Molecule.toFormat(Molecule.java:1116)





Sorry but I don't have a structure example yet

User f359e526a1

16-06-2007 09:02:37

Thanks, will notice the colleague who responsible for the SSSR code seems could not import the structure.

ChemAxon 25dcd765a3

17-06-2007 17:13:32

Could you please send the structure.


We need some information to reproduce and fix the bug.





thank you


Andras

User c23c5e9da4

21-06-2007 04:00:00

I've added some code to catch this and will try and deploy it to production tomorrow - it is hard to debug these runtime exceptions...

ChemAxon 25dcd765a3

21-06-2007 08:20:22

We have also tried to find the bug using the NCI database, but without success.





Andras

ChemAxon 25dcd765a3

21-06-2007 08:33:34

I have attached a test code which prints out the molecule number and run sssr detection.


The buggy molecule is right before the exception.





Copy the RingTest.java under the test directory or remove the first line ("package test").








Andras

User c23c5e9da4

12-07-2007 15:05:08

We are only seeing this error when creating mrvs of reactions - not individual molecules - i am working on getting a structure to you - but this error is causing up big problems.

ChemAxon 25dcd765a3

24-08-2007 15:47:07

Hi!





I'm sorry but this is not enough information us to find the bug.


Please send the reaction mrv file or any information how can we reproduce the bug.


Andras

User c23c5e9da4

25-08-2007 01:37:57

I understand but it is a little bit of a catch 22 in that I can't capture the mrv to reproduce this because I can't generate it - I've captured the molfile and can't reproduce it based on that. We have had to disable the feature that depends on this because it was causing our users so many problems so it is even harder to find now.

ChemAxon 25dcd765a3

04-09-2007 17:00:13

We have just found a bug that has maybe connection to this one.


It also appears during reaction generation, but it is reproducible with simple code using jchem API.(It is not possible to generate molecule and get the exception after.) So in that case the code is the only possibility to get the exception.


You may also consider to write a simple code which would generate the exception. As it is possible that you cannot catch the buggy molecule as it is generated somewhere in the code.

ChemAxon 25dcd765a3

08-09-2007 16:04:25

The related problem was the following:


It is not supported to embed different types of molecules in any way.


What does this mean:


If you want a reaction with Rgroups you should set up an RgMolecule and set the root of the RgMolecule to RxnMolecule.





The following for example is not supported:


Setting up an RxnMolecule which contains RgMolecule as a reagent and Molecule as product.





I hope this helps.


Andras

User 6ac84887cc

11-12-2008 10:57:36

Dear Andras,





I have the same problem, but with standardizer. Here I am attaching a molecule which will reproduce the error in the code posted by you. I just added the following line to it after line no 29





System.out.println(m.toFormat("smiles"));





I come across this problem in any programmatic attempt to access this molecule object, not only in standardizer.





Thanks and regards,





Ravindra





*************************************************


jchem.version=5.1.0


jchem.veruln=5_1_0


jchem.vernum=5.1.0


jchem.date=2008.08.07


jchem.table.version=50100


marvin.package=marvin-all-5_1_0.zip





os=MS Windows Server 2003 RC2 SP2


java version "1.6.0_10"


Java(TM) SE Runtime Environment (build 1.6.0_10-b33)


Java HotSpot(TM) Client VM (build 11.0-b15, mixed mode, sharing)


*************************************************

ChemAxon 0a9e2a55e1

12-12-2008 14:20:16

Hi!





Andras is on holiday now, but we will check this soon.





Best Regards,


Peter

ChemAxon e500b51457

16-12-2008 12:25:34

Dear Ravindra,





We're sorry for the late answer.


Thank you for reporting, this is indeed a bug in SMILES export.


We will notify you as soon as the correction is out.





Best Regards,


Erika

User 6ac84887cc

16-12-2008 12:35:36

Dear Erika,


Thanks for the reply. I can send you couple of more sample MOL files for this error, if that helps.





Best Regards,





Ravindra

ChemAxon e500b51457

17-12-2008 08:36:48

More sample files would help us a lot.





Thanks,


Erika.

ChemAxon 990acf0dec

30-01-2009 10:22:58

Hi Ravindra,





I've come across this topic, and tried out your test file (tes.mol). To be honest, I don't understand why did you create a superatom from the same structure three times, in addition, why did you create one of these superatoms on the top of another. Anyway, it seems that Marvin incorrectly imports this MOLFile, because after expanding the groups, the original structure is duplicated. We have to investigate this issue first.





To reproduce the SMILES export problem, could you please send us other test files?





Thank you and best regards,





Akos