[ZPatterns] Re: ZPatterns DATA LOSS BUG and FIX (0.4.3p1 patch release)

Juan David Ibáñez Palomar [email protected]
Tue, 26 Jun 2001 18:38:50 +0200 (METDST)


It still fails in Zope 2.4b1, with the following message:

Traceback (innermost last):
  File /home/jdavid/Zope-2.4.0b1/lib/python/OFS/Application.py, line 552, in import_product
  File /home/jdavid/Zope-2.4.0b1/lib/python/Products/LoginManager/__init__.py, line 1, in ?
  File /home/jdavid/Zope-2.4.0b1/lib/python/Products/LoginManager/LoginManager.py, line 8, in ?
    (Object: MakePICBase)
  File /home/jdavid/Zope-2.4.0b1/lib/python/Products/ZPatterns/__init__.py, line 1, in ?
  File /home/jdavid/Zope-2.4.0b1/lib/python/Products/ZPatterns/Rack.py, line 1, in ?
  File /home/jdavid/Zope-2.4.0b1/lib/python/Products/ZPatterns/DataManagers.py, line 6, in ?
    (Object: ComputedAttribute)
  File /home/jdavid/Zope-2.4.0b1/lib/python/Products/ZPatterns/AttributeProviders.py, line 8, in ?
    (Object: ComputedAttribute)
  File /home/jdavid/Zope-2.4.0b1/lib/python/Products/ZPatterns/Expressions.py, line 139, in ?
    (Object: ComputedAttribute)
NameError: name 'expr_globals' is not defined


It tries to delete expr_globals but it doesn't exists, a fix could
be to write "expr_globals = None" instead of "pass" at line 79 of
Expressions.py


jdavid


> 
> ZPatterns "0.4.3final" contains a serious bug which deletes all ZODB-stored
> contents of a Rack when you use the manage_pack method.  This bug only
> affects you if you store Rack-mounted objects or attributes in the ZODB,
> and does not affect you if your objects are entirely contained in an RDBMS
> or other mechanism external to the rack.  If you've upgraded to 0.4.3,
> please do not use manage_pack!
> 
> I have uploaded new versions of ZPatterns and PlugIns to fix the problem
> with packing racks, and to provide "experimental" support for Zope 2.4b1.
> (Specifically the problems reported below with expr_globals and ts_regex
> have been fixed.)  Please upgrade to 0.4.3p1 before using manage_pack, or
> if you wish to experiment with ZPatterns on Zope 2.4b1.  Thanks.
> 
> Thanks too, to Juan Palomar and Itai Tavor for providing information and
> patches.
> 
>