From: Michael T. (JIRA) <nh...@gm...> - 2011-05-24 16:04:45
|
Exception thrown when mapping contains empty enum ------------------------------------------------- Key: NH-2738 URL: http://216.121.112.228/browse/NH-2738 Project: NHibernate Issue Type: Bug Components: Mapping by-code Affects Versions: 3.2.0Beta1 Reporter: Michael Teper Priority: Minor I was playing around with new mapping by code and ConventionModelMapper and ran into an "Array ouf bounds exception". Turned out that one of my entities had an enum property and the enum was empty (I haven't yet added any values). As this was a pretty trivial project, the issue was easy to track down but it would be great if this was handled better by NH. Either this should be ignored (what's the harm?) or the error message should point out the empty enum and the class that was referencing it. Thank you! -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://216.121.112.228/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Fabio M. (JIRA) <nh...@gm...> - 2011-05-26 17:54:54
|
[ http://216.121.112.228/browse/NH-2738?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Fabio Maulo updated NH-2738: ---------------------------- Issue Type: Improvement (was: Bug) Since an empty enum does not have many sense what we can do is just throw a more descriptive exception > Exception thrown when mapping contains empty enum > ------------------------------------------------- > > Key: NH-2738 > URL: http://216.121.112.228/browse/NH-2738 > Project: NHibernate > Issue Type: Improvement > Components: Mapping by-code > Affects Versions: 3.2.0Beta1 > Reporter: Michael Teper > Priority: Minor > > I was playing around with new mapping by code and ConventionModelMapper and ran into an "Array ouf bounds exception". Turned out that one of my entities had an enum property and the enum was empty (I haven't yet added any values). As this was a pretty trivial project, the issue was easy to track down but it would be great if this was handled better by NH. Either this should be ignored (what's the harm?) or the error message should point out the empty enum and the class that was referencing it. > Thank you! -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://216.121.112.228/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Michael T. (JIRA) <nh...@gm...> - 2011-05-26 17:58:55
|
[ http://216.121.112.228/browse/NH-2738?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=21205#action_21205 ] Michael Teper commented on NH-2738: ----------------------------------- Whichever is easier, as long as the error message makes it easy to figure out what happened. (e.g. "Property Foo of type Bar could not be mapped because the enum does not contain any members", or something to that effect. Thank you! > Exception thrown when mapping contains empty enum > ------------------------------------------------- > > Key: NH-2738 > URL: http://216.121.112.228/browse/NH-2738 > Project: NHibernate > Issue Type: Improvement > Components: Mapping by-code > Affects Versions: 3.2.0Beta1 > Reporter: Michael Teper > Priority: Minor > > I was playing around with new mapping by code and ConventionModelMapper and ran into an "Array ouf bounds exception". Turned out that one of my entities had an enum property and the enum was empty (I haven't yet added any values). As this was a pretty trivial project, the issue was easy to track down but it would be great if this was handled better by NH. Either this should be ignored (what's the harm?) or the error message should point out the empty enum and the class that was referencing it. > Thank you! -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://216.121.112.228/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Fabio M. (JIRA) <nh...@gm...> - 2011-05-30 16:03:41
|
[ http://216.121.112.228/browse/NH-2738?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Fabio Maulo updated NH-2738: ---------------------------- Component/s: (was: Mapping by-code) Core > Exception thrown when mapping contains empty enum > ------------------------------------------------- > > Key: NH-2738 > URL: http://216.121.112.228/browse/NH-2738 > Project: NHibernate > Issue Type: Improvement > Components: Core > Affects Versions: 3.2.0Beta1 > Reporter: Michael Teper > Priority: Minor > > I was playing around with new mapping by code and ConventionModelMapper and ran into an "Array ouf bounds exception". Turned out that one of my entities had an enum property and the enum was empty (I haven't yet added any values). As this was a pretty trivial project, the issue was easy to track down but it would be great if this was handled better by NH. Either this should be ignored (what's the harm?) or the error message should point out the empty enum and the class that was referencing it. > Thank you! -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://216.121.112.228/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Fabio M. (JIRA) <nh...@gm...> - 2011-05-30 16:13:41
|
[ http://216.121.112.228/browse/NH-2738?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Fabio Maulo resolved NH-2738. ----------------------------- Resolution: Fixed Fix Version/s: 3.2.0Beta2 > Exception thrown when mapping contains empty enum > ------------------------------------------------- > > Key: NH-2738 > URL: http://216.121.112.228/browse/NH-2738 > Project: NHibernate > Issue Type: Improvement > Components: Core > Affects Versions: 3.2.0Beta1 > Reporter: Michael Teper > Priority: Minor > Fix For: 3.2.0Beta2 > > > I was playing around with new mapping by code and ConventionModelMapper and ran into an "Array ouf bounds exception". Turned out that one of my entities had an enum property and the enum was empty (I haven't yet added any values). As this was a pretty trivial project, the issue was easy to track down but it would be great if this was handled better by NH. Either this should be ignored (what's the harm?) or the error message should point out the empty enum and the class that was referencing it. > Thank you! -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://216.121.112.228/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |