Error Value: 'Set' object has no attribute 'count'
I am getting an error message when Zope is trying to evaluate the following: elif string.count(product_info['product']['options'],'lookup') == 1: The error message is: Error Value: 'Set' object has no attribute 'count' I have two instances of Zope running. On Zope 2.8.2-final, python 2.3.5, linux2, this does not occur. On Zope 2.8.7-1.el4.rf, python 2.3.4, linux2, it does occur. Could anyone suggest a solution? Thanks and regards Cameron
--On 19. Februar 2007 22:18:38 +1300 kjcsb <kjcsb@orcon.net.nz> wrote:
I am getting an error message when Zope is trying to evaluate the following:
elif string.count(product_info['product']['options'],'lookup') == 1:
The error message is: Error Value: 'Set' object has no attribute 'count'
How reproduce with an out-of-the-box Zope installation? -aj
kjcsb wrote at 2007-2-19 22:18 +1300:
I am getting an error message when Zope is trying to evaluate the following:
elif string.count(product_info['product']['options'],'lookup') == 1:
The error message is: Error Value: 'Set' object has no attribute 'count'
Apparently "string" is a "Set" object in your context and not the "string" module as you expect. -- Dieter
kjcsb wrote:
I am getting an error message when Zope is trying to evaluate the following:
elif string.count(product_info['product']['options'],'lookup') == 1:
Wild guess: Zwarehouse? Have you tried that mailing list? http://www.zwarehouse.org/wiki/MailList Traceback (innermost last): * Module ZPublisher.Publish, line 101, in publish * Module ZPublisher.mapply, line 88, in mapply * Module ZPublisher.Publish, line 39, in call_object * Module Products.Skins.FSPythonScript, line 108, in __call__ * Module Shared.DC.Scripts.Bindings, line 306, in __call__ * Module Shared.DC.Scripts.Bindings, line 343, in _bindAndExec * Module Products.Skins.FSPythonScript, line 163, in _exec * Module None, line 35, in product_info <FSPythonScript at /my_site/zwarehouse/ZWarehouse/product_info> Line 35 * Module Products.ZWarehouse.ZWarehouseBase, line 1076, in fullProductInformation * Module Products.ZWarehouse.ZWarehouseBase, line 957, in define_tax_for_product * Module string, line 165, in count AttributeError: 'Set' object has no attribute 'count' Can anybody suggest an alternative to Zwarehouse? Norbert
participants (4)
-
Andreas Jung -
Dieter Maurer -
kjcsb -
Norbert Marrale