[ZPatterns] _v_dm_ KeyError calling get_transaction().abort()

Itai Tavor [email protected]
Mon, 8 Oct 2001 11:31:10 +1000


Hi,

I have a method of a DataSkin object that looks something like this:

     def editMe(self, REQUEST, RESPONSE):
         """ Edit object for customer """
         ...
         ...
         if errors.has_any():
             get_transaction().abort()
             html = getattr(self, 'edit.html')(self, REQUEST, errors=errors)
             raise FormError, html


The html = getattr() line causes the following exception. If I remove 
the abort() line, this does not happen. Using Zope 2.3.2, ZPatterns 
0.4.3p2. I never had to abort transactions before, so I might be 
doing something bad... but I can't see what it might be. Any ideas?


Error Type: KeyError
Error Value: _v_dm_

Traceback (innermost last):
   File /usr/local/zope/2.3.2/lib/python/ZPublisher/Publish.py, line 
223, in publish_module
   File /usr/local/zope/2.3.2/lib/python/ZPublisher/Publish.py, line 
187, in publish
   File /usr/local/zope/2.3.2/lib/python/Zope/__init__.py, line 221, 
in zpublisher_exception_hook
     (Object: 711)
   File /usr/local/zope/2.3.2/lib/python/ZPublisher/Publish.py, line 
171, in publish
   File /usr/local/zope/2.3.2/lib/python/ZPublisher/mapply.py, line 
160, in mapply
     (Object: editMe)
   File /usr/local/zope/2.3.2/lib/python/ZPublisher/Publish.py, line 
112, in call_object
     (Object: editMe)
   File /Users/itai/Z/Main/Products/PrintShop/Item.py, line 113, in editMe
     (Object: 711)
   File /Users/itai/Z/Main/Products/ZPatterns/DataSkins.py, line 217, 
in __get_attr__
     (Object: 711)
KeyError: (see above)


-- 
--
Itai Tavor                      -- "Je sautille, donc je suis."    --
[email protected]            --               - Kermit the Frog --
--                                                                 --
-- "If you haven't got your health, you haven't got anything"      --