From: Max R. A. <ma...@eo...> - 2002-12-05 15:27:34
|
Hi! By "accident" I updated an object instance which id was associated with another loaded instance in the current instance and got the following error: "Another object was associated with this id (the object with the given id was already loaded)" That is all fine, but would it not be nice if the exception message contained some more information about this object ? Currently we have to enable trace to see which class and id that is related to the exception. With trace enabled you would get: "updating eg.FooBar#42" This is actually a typical scenario for a couple of dozens exceptions thrown when saving, updating, etc. How about adding that vital information to the exception message without enabling the trace ? So we instead would get: "Another object was associated with this id (the object with the given id was already loaded) [eg.FooBar#42]" Any comments ? Otherwise I will send a patch for this change ? /max |