Paul Winkler wrote:
On Mon, Feb 10, 2003 at 06:11:15PM -0200, Leonardo Rochael Almeida wrote:Please, please, please, don't use generic "except:". They can cause ZODB corruption if they catch ConflictErrors.Can anyone else confirm or deny??? If true, it needs to be much more widely publicized!
It's an open bug on Sourceforge: http://sourceforge.net/tracker/index.php?func=detail&aid=637279&group_id=15628&atid=115628
"tal:on-error" also catches all exceptions. It could be made to catch all exceptions except ConflictError, but I don't feel like that's the right solution. I think the right solution is to prevent applications from committing potentially conflicting data, even when ConflictErrors are ignored.Great, so there's at least 133 things to examine to see if they could catch a ConflictError. And I only wrote about 15 of those. The rest could be very time-consuming to audit.
This doesn't seem to be a showstopper for now, but as more applications use ZODB, it could become a bigger problem.
Zope-Dev maillist - [EMAIL PROTECTED]
** No cross posts or HTML encoding! **
(Related lists - http://mail.zope.org/mailman/listinfo/zope-announce