[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
Hello guys, It's good that I've been on the vacations =) As it seems that the bug is not in Mono, but in NH. So, the correct fix for this issue is in [XmlIgnore] position and svn version should work fine? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups nhusers group. To post to this group, send email to nhusers@googlegroups.com To unsubscribe from this group, send email to nhusers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~--~~~~--~~--~--~---
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
This needs re-opening (NH-1865)... [XmlIgnore] are in the wrong places. They should be here... [XmlIgnore] public virtual IDictionarystring, MetaAttribute MappedMetaData { [XmlIgnore] public IDictionarystring, MetaAttribute InheritableMetaData { On Jul 13, 6:05 pm, Patrick McEvoy patrick.mce...@gmail.com wrote: dell, can you post the patch or provide link tomonobugzilla? Ricardo has created an issue onmonobugzilla and themonoguys have an interesting response This repro (and then likely NHibernate) makes nasty use of .NET exploit that inconsistently allows dictionary serialization which is explicitly prohibited. It is proved when the sample repro is modified to hold Dictionarystring,string instead of IDictionarystring,string, then .NET raises InvalidOperationException. Our serialization engine is designed to explicitly to exclude such dictionary serialization. We may have to fix some ICollection-based serialization, but such use won't be popular (-MINOR), and it is absolutely not for this kind of IDictionary, use. https://bugzilla.novell.com/show_bug.cgi?id=519442 On Jul 7, 12:00 pm, deil an...@tinuviel.ru wrote: Hello again, I have managed to patchMonoand get NH trunk up running! Now I will try to create a reproducable test and send it toMonoteam. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups nhusers group. To post to this group, send email to nhusers@googlegroups.com To unsubscribe from this group, send email to nhusers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~--~~~~--~~--~--~---
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
Ok. 2009/7/18 Patrick McEvoy patrick.mce...@gmail.com This needs re-opening (NH-1865)... [XmlIgnore] are in the wrong places. They should be here... [XmlIgnore] public virtual IDictionarystring, MetaAttribute MappedMetaData { [XmlIgnore] public IDictionarystring, MetaAttribute InheritableMetaData { On Jul 13, 6:05 pm, Patrick McEvoy patrick.mce...@gmail.com wrote: dell, can you post the patch or provide link tomonobugzilla? Ricardo has created an issue onmonobugzilla and themonoguys have an interesting response This repro (and then likely NHibernate) makes nasty use of .NET exploit that inconsistently allows dictionary serialization which is explicitly prohibited. It is proved when the sample repro is modified to hold Dictionarystring,string instead of IDictionarystring,string, then .NET raises InvalidOperationException. Our serialization engine is designed to explicitly to exclude such dictionary serialization. We may have to fix some ICollection-based serialization, but such use won't be popular (-MINOR), and it is absolutely not for this kind of IDictionary, use. https://bugzilla.novell.com/show_bug.cgi?id=519442 On Jul 7, 12:00 pm, deil an...@tinuviel.ru wrote: Hello again, I have managed to patchMonoand get NH trunk up running! Now I will try to create a reproducable test and send it toMonoteam. -- Fabio Maulo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups nhusers group. To post to this group, send email to nhusers@googlegroups.com To unsubscribe from this group, send email to nhusers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~--~~~~--~~--~--~---
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
dell, can you post the patch or provide link to mono bugzilla? Ricardo has created an issue on mono bugzilla and the mono guys have an interesting response This repro (and then likely NHibernate) makes nasty use of .NET exploit that inconsistently allows dictionary serialization which is explicitly prohibited. It is proved when the sample repro is modified to hold Dictionarystring,string instead of IDictionarystring,string, then .NET raises InvalidOperationException. Our serialization engine is designed to explicitly to exclude such dictionary serialization. We may have to fix some ICollection-based serialization, but such use won't be popular (-MINOR), and it is absolutely not for this kind of IDictionary, use. https://bugzilla.novell.com/show_bug.cgi?id=519442 On Jul 7, 12:00 pm, deil an...@tinuviel.ru wrote: Hello again, I have managed to patch Mono and get NH trunk up running! Now I will try to create a reproducable test and send it to Mono team. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups nhusers group. To post to this group, send email to nhusers@googlegroups.com To unsubscribe from this group, send email to nhusers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~--~~~~--~~--~--~---
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
Ah beautiful! I can't wait to get this running again on mono. Thanks! Curtis. On Jul 7, 4:00 am, deil an...@tinuviel.ru wrote: Hello again, I have managed to patch Mono and get NH trunk up running! Now I will try to create a reproducable test and send it to Mono team. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups nhusers group. To post to this group, send email to nhusers@googlegroups.com To unsubscribe from this group, send email to nhusers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~--~~~~--~~--~--~---
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
Well done Antón!!Thanks. 2009/7/7 deil an...@tinuviel.ru Hello again, I have managed to patch Mono and get NH trunk up running! Now I will try to create a reproducable test and send it to Mono team. -- Fabio Maulo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups nhusers group. To post to this group, send email to nhusers@googlegroups.com To unsubscribe from this group, send email to nhusers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~--~~~~--~~--~--~---
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
2009/7/6 Fabio Maulo fabioma...@gmail.com: No that mean that mean that if you can prove that the cause is inside NH and we can do something ok. Not being an expert in NHibernate architecture, how exactly should I go about proving this? Some more information here would be helpful. If you can't prove that the problem is inside NH well... you should find the place where create the issue. This doesn't seem very helpful: isn't the NHibernate team interested in seeing NHibernate working on Mono? When a framework is working without problems on windows and has a problem in Mono the most probably is an issue in Mono, and Mono's users should help to improve it and not asking workaround everywhere. I must admit, I'm not sure I understand your attitude: the bug was being seemed to be thrown from a call to the NHibernate framework, so the first place I raised it was with you guys. This seems like a reasonable first step to me, and I don't see how this is asking workaround everywhere. If the issue is with Mono, it would be helpful if you could point me in the right direction, letting me know which Mono/System/NHibernate class is causing the problem. We all benefit if I can find the right result and raise it with the correct people. Sincerely... -- Ricardo Gladwell --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups nhusers group. To post to this group, send email to nhusers@googlegroups.com To unsubscribe from this group, send email to nhusers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~--~~~~--~~--~--~---
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
Hello guys, I have the same issue. And think the problem is not inside NH: It uses IDictionarystring, MetaAttribute and Mono, according to sources, thinks that to be serializable, it should have a method Add (KeyValuePairstring, MetaAttribute), but can't find it through reflection. But as IDictionaryTKey, TValue is defined as extending ICollectionKeyValuePairTKey, TValue, this method should exist. So, the problem is somewhere inside Mono's reflection or Xml serialization code. I need some more time to understand all it completely --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups nhusers group. To post to this group, send email to nhusers@googlegroups.com To unsubscribe from this group, send email to nhusers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~--~~~~--~~--~--~---
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
The issue was closed because: 1) Opened as critical, later was changed, and Critical means: NHibernate can't work without this issue working. 2) Absence of a simple test case to reproduce the problem. 3) The issue seems to be on Mono side, and not in NHibernate. I counted 3 people saying that are experimenting this issue, you guys should join together, create a test-case and send to the Mono team. I don't know how this can be a problem. On Sun, Jul 5, 2009 at 7:51 PM, Ricardo ricardo.gladw...@gmail.com wrote: I'm getting the same issue running NHibernate on Mono with Linux (but not with Windows for some reason). Attempted to raise a defect with NHibernate JIRA: http://nhjira.koah.net/browse/NH-1865 But my issue was closed almost immediately, and I'm still none the wiser as to the cause: The problem, may be, was caused by some not serializable classes (now serializable). If that was not the problem please add the issue to the Mono issue tracker because Mono should work as .NET. Does this mean that defects with NHibernate on Mono should never be raised against NHibernate because Mono should work as .NET? On Jun 25, 11:16 am, Luca Del Tongo luk...@gmail.com wrote: I'm facing the same problem as Bryan stated, with the same configuration. Any ideas? On Jun 23, 12:50 am, Bryan Murphy bmurphy1...@gmail.com wrote: Hey guys, I'm running into the a problem compiling our hbm filesunderMonov2.4 and NHibernatev2.1.0beta2. Looking through the code, it looks like the problem is how the XmlSerializer interprets AbstractDecoratable and the culprits are the properties MappedMetaData and InheritableMetaData. The exception I'm getting is below. Thanks, Bryan NHibernate.MappingException: Could not compile the mapping document: **SNIP**.Domain.hbm.xml --- System.InvalidOperationException: There was an error reflecting type 'NHibernate.Cfg.MappingSchema.HbmMapping'. --- System.InvalidOperationException: To be XML serializable, types which inherit from ICollection must have an implementation of Add(System.Collections.Generic.KeyValuePair`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]]) at all levels of their inheritance hierarchy. System.Collections.Generic.IDictionary`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]] does not implement Add(System.Collections.Generic.KeyValuePair`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]]). at System.Xml.Serialization.TypeData.get_ListItemType () [0x00230] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:342 at System.Xml.Serialization.TypeData.get_ListItemTypeData () [0x00016] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:274 at System.Xml.Serialization.TypeData..ctor (System.Type type, System.String elementName, Boolean isPrimitive, System.Xml.Serialization.TypeData mappedType, System.Xml.Schema.XmlSchemaPatternFacet facet) [0x00104] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:94 at System.Xml.Serialization.TypeData..ctor (System.Type type, System.String elementName, Boolean isPrimitive) [0x0] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.XPath/Parser.cs:1 at System.Xml.Serialization.TypeTranslator.GetTypeData (System.Type runtimeType, System.String xmlDataType) [0x00241] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeTranslator.cs:243 at System.Xml.Serialization.TypeTranslator.GetTypeData (System.Type type) [0x0] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeTranslator.cs:163 at System.Xml.Serialization.XmlReflectionImporter.GetReflectionMembers (System.Type type) [0x00244] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:774 at System.Xml.Serialization.XmlReflectionImporter.ImportClassMapping (System.Xml.Serialization.TypeData typeData, System.Xml.Serialization.XmlRootAttribute root, System.String defaultNamespace) [0x0007a] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:343 at System.Xml.Serialization.XmlReflectionImporter.ImportTypeMapping (System.Xml.Serialization.TypeData typeData, System.Xml.Serialization.XmlRootAttribute root, System.String defaultNamespace) [0x0006e] in
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
Hi Dario, To explain, the problem here was that: 1. The issue was marked closed and I was told to raise it somewhere but I still don't understand why NHibernate is failing on Mono, so what exactly am I supposed to raise with Mono? 2. For Mono users I guess the issue is Critical. If it can be downgraded that's fine, but I don't understand why that means it should be closed. I'm not sure I understand the hostility at this particular project. I'll try some other ORM framework. Good luck.. Ricardo Gladwell ricardo.gladw...@gmail.com 2009/7/6 Dario Quintana conta...@darioquintana.com.ar: The issue was closed because: 1) Opened as critical, later was changed, and Critical means: NHibernate can't work without this issue working. 2) Absence of a simple test case to reproduce the problem. 3) The issue seems to be on Mono side, and not in NHibernate. I counted 3 people saying that are experimenting this issue, you guys should join together, create a test-case and send to the Mono team. I don't know how this can be a problem. On Sun, Jul 5, 2009 at 7:51 PM, Ricardo ricardo.gladw...@gmail.com wrote: I'm getting the same issue running NHibernate on Mono with Linux (but not with Windows for some reason). Attempted to raise a defect with NHibernate JIRA: http://nhjira.koah.net/browse/NH-1865 But my issue was closed almost immediately, and I'm still none the wiser as to the cause: The problem, may be, was caused by some not serializable classes (now serializable). If that was not the problem please add the issue to the Mono issue tracker because Mono should work as .NET. Does this mean that defects with NHibernate on Mono should never be raised against NHibernate because Mono should work as .NET? On Jun 25, 11:16 am, Luca Del Tongo luk...@gmail.com wrote: I'm facing the same problem as Bryan stated, with the same configuration. Any ideas? On Jun 23, 12:50 am, Bryan Murphy bmurphy1...@gmail.com wrote: Hey guys, I'm running into the a problem compiling our hbm filesunderMonov2.4 and NHibernatev2.1.0beta2. Looking through the code, it looks like the problem is how the XmlSerializer interprets AbstractDecoratable and the culprits are the properties MappedMetaData and InheritableMetaData. The exception I'm getting is below. Thanks, Bryan NHibernate.MappingException: Could not compile the mapping document: **SNIP**.Domain.hbm.xml --- System.InvalidOperationException: There was an error reflecting type 'NHibernate.Cfg.MappingSchema.HbmMapping'. --- System.InvalidOperationException: To be XML serializable, types which inherit from ICollection must have an implementation of Add(System.Collections.Generic.KeyValuePair`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]]) at all levels of their inheritance hierarchy. System.Collections.Generic.IDictionary`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]] does not implement Add(System.Collections.Generic.KeyValuePair`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]]). at System.Xml.Serialization.TypeData.get_ListItemType () [0x00230] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:342 at System.Xml.Serialization.TypeData.get_ListItemTypeData () [0x00016] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:274 at System.Xml.Serialization.TypeData..ctor (System.Type type, System.String elementName, Boolean isPrimitive, System.Xml.Serialization.TypeData mappedType, System.Xml.Schema.XmlSchemaPatternFacet facet) [0x00104] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:94 at System.Xml.Serialization.TypeData..ctor (System.Type type, System.String elementName, Boolean isPrimitive) [0x0] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.XPath/Parser.cs:1 at System.Xml.Serialization.TypeTranslator.GetTypeData (System.Type runtimeType, System.String xmlDataType) [0x00241] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeTranslator.cs:243 at System.Xml.Serialization.TypeTranslator.GetTypeData (System.Type type) [0x0] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeTranslator.cs:163 at System.Xml.Serialization.XmlReflectionImporter.GetReflectionMembers (System.Type type) [0x00244] in
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
Hi Ricardo. Take it easy Ricardo, nobody is being hostile here :) I my opinion it's a Mono problem, and you should create an issue here http://mono-project.com/Bugs. If it's a Mono bug, there is nothing we can do. Or Maybe if we find the problem, we can workaround it, but I don't think is a good idea, Mono is a open source project, so like NHibernate you can report this issue and wait to the commiters fix the problems, and with a patch this may go faster. I hope this clarify the situation. Cheers On Mon, Jul 6, 2009 at 7:36 AM, Ricardo Gladwell ricardo.gladw...@gmail.com wrote: Hi Dario, To explain, the problem here was that: 1. The issue was marked closed and I was told to raise it somewhere but I still don't understand why NHibernate is failing on Mono, so what exactly am I supposed to raise with Mono? 2. For Mono users I guess the issue is Critical. If it can be downgraded that's fine, but I don't understand why that means it should be closed. I'm not sure I understand the hostility at this particular project. I'll try some other ORM framework. Good luck.. Ricardo Gladwell ricardo.gladw...@gmail.com -- -- Dario Quintana http://darioquintana.com.ar --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups nhusers group. To post to this group, send email to nhusers@googlegroups.com To unsubscribe from this group, send email to nhusers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~--~~~~--~~--~--~---
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
2009/7/6 Ricardo Gladwell ricardo.gladw...@gmail.com I'll try some other ORM framework. Good luck.. Good solution! I hope that all OpenSource users does not have your attitude, instead I hope all has the Anton's attitude (Anton aka deil see mail above). Thanks Anton to investigate the problem: try to recreate it with a test and then send the test to Mono team. -- Fabio Maulo --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups nhusers group. To post to this group, send email to nhusers@googlegroups.com To unsubscribe from this group, send email to nhusers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nhusers?hl=en -~--~~~~--~~--~--~---
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
I'm getting the same issue running NHibernate on Mono with Linux (but not with Windows for some reason). Attempted to raise a defect with NHibernate JIRA: http://nhjira.koah.net/browse/NH-1865 But my issue was closed almost immediately, and I'm still none the wiser as to the cause: The problem, may be, was caused by some not serializable classes (now serializable). If that was not the problem please add the issue to the Mono issue tracker because Mono should work as .NET. Does this mean that defects with NHibernate on Mono should never be raised against NHibernate because Mono should work as .NET? On Jun 25, 11:16 am, Luca Del Tongo luk...@gmail.com wrote: I'm facing the same problem as Bryan stated, with the same configuration. Any ideas? On Jun 23, 12:50 am, Bryan Murphy bmurphy1...@gmail.com wrote: Hey guys, I'm running into the a problem compiling our hbm filesunderMonov2.4 and NHibernatev2.1.0beta2. Looking through the code, it looks like the problem is how the XmlSerializer interprets AbstractDecoratable and the culprits are the properties MappedMetaData and InheritableMetaData. The exception I'm getting is below. Thanks, Bryan NHibernate.MappingException: Could not compile the mapping document: **SNIP**.Domain.hbm.xml --- System.InvalidOperationException: There was an error reflecting type 'NHibernate.Cfg.MappingSchema.HbmMapping'. --- System.InvalidOperationException: To be XML serializable, types which inherit from ICollection must have an implementation of Add(System.Collections.Generic.KeyValuePair`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]]) at all levels of their inheritance hierarchy. System.Collections.Generic.IDictionary`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]] does not implement Add(System.Collections.Generic.KeyValuePair`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]]). at System.Xml.Serialization.TypeData.get_ListItemType () [0x00230] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:342 at System.Xml.Serialization.TypeData.get_ListItemTypeData () [0x00016] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:274 at System.Xml.Serialization.TypeData..ctor (System.Type type, System.String elementName, Boolean isPrimitive, System.Xml.Serialization.TypeData mappedType, System.Xml.Schema.XmlSchemaPatternFacet facet) [0x00104] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:94 at System.Xml.Serialization.TypeData..ctor (System.Type type, System.String elementName, Boolean isPrimitive) [0x0] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.XPath/Parser.cs:1 at System.Xml.Serialization.TypeTranslator.GetTypeData (System.Type runtimeType, System.String xmlDataType) [0x00241] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeTranslator.cs:243 at System.Xml.Serialization.TypeTranslator.GetTypeData (System.Type type) [0x0] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeTranslator.cs:163 at System.Xml.Serialization.XmlReflectionImporter.GetReflectionMembers (System.Type type) [0x00244] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:774 at System.Xml.Serialization.XmlReflectionImporter.ImportClassMapping (System.Xml.Serialization.TypeData typeData, System.Xml.Serialization.XmlRootAttribute root, System.String defaultNamespace) [0x0007a] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:343 at System.Xml.Serialization.XmlReflectionImporter.ImportTypeMapping (System.Xml.Serialization.TypeData typeData, System.Xml.Serialization.XmlRootAttribute root, System.String defaultNamespace) [0x0006e] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:217 --- End of inner exception stack trace --- at System.Xml.Serialization.XmlReflectionImporter.ImportTypeMapping (System.Xml.Serialization.TypeData typeData, System.Xml.Serialization.XmlRootAttribute root, System.String defaultNamespace) [0x00179] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:237 at System.Xml.Serialization.XmlReflectionImporter.ImportTypeMapping (System.Type type, System.Xml.Serialization.XmlRootAttribute root,
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
No that mean that mean that if you can prove that the cause is inside NH and we can do something ok.If you can't prove that the problem is inside NH well... you should find the place where create the issue. NH's is for NH issues and not for mono isees nor for DataProvider issues nor RDBMS issues and so on. Btw Mono should work at least as NET. When a framework is working without problems on windows and has a problem in Mono the most probably is an issue in Mono, and Mono's users should help to improve it and not asking workaround everywhere. 2009/7/5 Ricardo ricardo.gladw...@gmail.com I'm getting the same issue running NHibernate on Mono with Linux (but not with Windows for some reason). Attempted to raise a defect with NHibernate JIRA: http://nhjira.koah.net/browse/NH-1865 But my issue was closed almost immediately, and I'm still none the wiser as to the cause: The problem, may be, was caused by some not serializable classes (now serializable). If that was not the problem please add the issue to the Mono issue tracker because Mono should work as .NET. Does this mean that defects with NHibernate on Mono should never be raised against NHibernate because Mono should work as .NET? On Jun 25, 11:16 am, Luca Del Tongo luk...@gmail.com wrote: I'm facing the same problem as Bryan stated, with the same configuration. Any ideas? On Jun 23, 12:50 am, Bryan Murphy bmurphy1...@gmail.com wrote: Hey guys, I'm running into the a problem compiling our hbm filesunderMonov2.4 and NHibernatev2.1.0beta2. Looking through the code, it looks like the problem is how the XmlSerializer interprets AbstractDecoratable and the culprits are the properties MappedMetaData and InheritableMetaData. The exception I'm getting is below. Thanks, Bryan NHibernate.MappingException: Could not compile the mapping document: **SNIP**.Domain.hbm.xml --- System.InvalidOperationException: There was an error reflecting type 'NHibernate.Cfg.MappingSchema.HbmMapping'. --- System.InvalidOperationException: To be XML serializable, types which inherit from ICollection must have an implementation of Add(System.Collections.Generic.KeyValuePair`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]]) at all levels of their inheritance hierarchy. System.Collections.Generic.IDictionary`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]] does not implement Add(System.Collections.Generic.KeyValuePair`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]]). at System.Xml.Serialization.TypeData.get_ListItemType () [0x00230] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:342 at System.Xml.Serialization.TypeData.get_ListItemTypeData () [0x00016] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:274 at System.Xml.Serialization.TypeData..ctor (System.Type type, System.String elementName, Boolean isPrimitive, System.Xml.Serialization.TypeData mappedType, System.Xml.Schema.XmlSchemaPatternFacet facet) [0x00104] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:94 at System.Xml.Serialization.TypeData..ctor (System.Type type, System.String elementName, Boolean isPrimitive) [0x0] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.XPath/Parser.cs:1 at System.Xml.Serialization.TypeTranslator.GetTypeData (System.Type runtimeType, System.String xmlDataType) [0x00241] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeTranslator.cs:243 at System.Xml.Serialization.TypeTranslator.GetTypeData (System.Type type) [0x0] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeTranslator.cs:163 at System.Xml.Serialization.XmlReflectionImporter.GetReflectionMembers (System.Type type) [0x00244] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:774 at System.Xml.Serialization.XmlReflectionImporter.ImportClassMapping (System.Xml.Serialization.TypeData typeData, System.Xml.Serialization.XmlRootAttribute root, System.String defaultNamespace) [0x0007a] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:343 at System.Xml.Serialization.XmlReflectionImporter.ImportTypeMapping (System.Xml.Serialization.TypeData typeData,
[nhusers] Re: v2.1.0 beta 2 bug under mono 2.4
I'm facing the same problem as Bryan stated, with the same configuration. Any ideas? On Jun 23, 12:50 am, Bryan Murphy bmurphy1...@gmail.com wrote: Hey guys, I'm running into the a problem compiling our hbm files under Mono v2.4 and NHibernate v2.1.0 beta 2. Looking through the code, it looks like the problem is how the XmlSerializer interprets AbstractDecoratable and the culprits are the properties MappedMetaData and InheritableMetaData. The exception I'm getting is below. Thanks, Bryan NHibernate.MappingException: Could not compile the mapping document: **SNIP**.Domain.hbm.xml --- System.InvalidOperationException: There was an error reflecting type 'NHibernate.Cfg.MappingSchema.HbmMapping'. --- System.InvalidOperationException: To be XML serializable, types which inherit from ICollection must have an implementation of Add(System.Collections.Generic.KeyValuePair`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]]) at all levels of their inheritance hierarchy. System.Collections.Generic.IDictionary`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]] does not implement Add(System.Collections.Generic.KeyValuePair`2[[System.String, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[NHibernate.Mapping.MetaAttribute, NHibernate, Version=2.1.0.2002, Culture=neutral, PublicKeyToken=aa95f207798dfdb4]]). at System.Xml.Serialization.TypeData.get_ListItemType () [0x00230] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:342 at System.Xml.Serialization.TypeData.get_ListItemTypeData () [0x00016] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:274 at System.Xml.Serialization.TypeData..ctor (System.Type type, System.String elementName, Boolean isPrimitive, System.Xml.Serialization.TypeData mappedType, System.Xml.Schema.XmlSchemaPatternFacet facet) [0x00104] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeData.cs:94 at System.Xml.Serialization.TypeData..ctor (System.Type type, System.String elementName, Boolean isPrimitive) [0x0] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.XPath/Parser.cs:1 at System.Xml.Serialization.TypeTranslator.GetTypeData (System.Type runtimeType, System.String xmlDataType) [0x00241] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeTranslator.cs:243 at System.Xml.Serialization.TypeTranslator.GetTypeData (System.Type type) [0x0] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/TypeTranslator.cs:163 at System.Xml.Serialization.XmlReflectionImporter.GetReflectionMembers (System.Type type) [0x00244] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:774 at System.Xml.Serialization.XmlReflectionImporter.ImportClassMapping (System.Xml.Serialization.TypeData typeData, System.Xml.Serialization.XmlRootAttribute root, System.String defaultNamespace) [0x0007a] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:343 at System.Xml.Serialization.XmlReflectionImporter.ImportTypeMapping (System.Xml.Serialization.TypeData typeData, System.Xml.Serialization.XmlRootAttribute root, System.String defaultNamespace) [0x0006e] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:217 --- End of inner exception stack trace --- at System.Xml.Serialization.XmlReflectionImporter.ImportTypeMapping (System.Xml.Serialization.TypeData typeData, System.Xml.Serialization.XmlRootAttribute root, System.String defaultNamespace) [0x00179] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:237 at System.Xml.Serialization.XmlReflectionImporter.ImportTypeMapping (System.Type type, System.Xml.Serialization.XmlRootAttribute root, System.String defaultNamespace) [0x0003c] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlReflectionImporter.cs:192 at System.Xml.Serialization.XmlSerializer..ctor (System.Type type, System.Xml.Serialization.XmlAttributeOverrides overrides, System.Type[] extraTypes, System.Xml.Serialization.XmlRootAttribute root, System.String defaultNamespace) [0x00047] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.Serialization/XmlSerializer.cs:226 at System.Xml.Serialization.XmlSerializer..ctor (System.Type type) [0x0] in /root/mono2.4/mono-2.4/mcs/class/System.XML/System.Xml.XPath/Parser.cs:1 at NHibernate.Cfg.XmlHbmBinding.Binder.Deserialize[HbmMapping] (System.Xml.XmlNode node)