Alexey Morozov
2005-07-01 05:28:17 UTC
Hello!
It seems there's a bug in ZSQLCatalog/ZSQLCatalog.py or I use it somehow
incorrectly (really don't know what's wrong).
I told yesterday that I got the following error after clicking on 'Find
and catalog' button in 'Find objects' tab. Here's the traceback:
---------------------------------
Traceback (innermost last):
* Module ZPublisher.Publish, line 175, in publish_module_standard
* Module Products.iHotfix, line 88, in new_publish
* Module ZPublisher.Publish, line 132, in publish
* Module Zope.App.startup, line 204, in zpublisher_exception_hook
* Module ZPublisher.Publish, line 101, in publish
* Module ZPublisher.mapply, line 88, in mapply
* Module ZPublisher.Publish, line 39, in call_object
* Module Products.ZSQLCatalog.ZSQLCatalog, line 551, in
manage_catalogFoundItems
NameError: global name 'time' is not defined (Also, an error occurred
while attempting to render the standard error message.)
--------------------------------
The problem code is
--------------------
obj_roles=obj_roles, obj_permission=obj_p
-> elapse = time.time()
-> c_elapse = time.clock()
words = 0
--------------------
Indeed the module doesn't import time at all and I could find any place
where it could be imported implicitly.
When I fixed that error (by adding import time), I was faced w/ another
missing import: urllib is used at line 578 but isn't imported.
I played w/ ZSQLCatalog-0.9-1mdk - derived RPM, but as I can see in CVS,
there's no corresponding fixes in trunk.
It seems there's a bug in ZSQLCatalog/ZSQLCatalog.py or I use it somehow
incorrectly (really don't know what's wrong).
I told yesterday that I got the following error after clicking on 'Find
and catalog' button in 'Find objects' tab. Here's the traceback:
---------------------------------
Traceback (innermost last):
* Module ZPublisher.Publish, line 175, in publish_module_standard
* Module Products.iHotfix, line 88, in new_publish
* Module ZPublisher.Publish, line 132, in publish
* Module Zope.App.startup, line 204, in zpublisher_exception_hook
* Module ZPublisher.Publish, line 101, in publish
* Module ZPublisher.mapply, line 88, in mapply
* Module ZPublisher.Publish, line 39, in call_object
* Module Products.ZSQLCatalog.ZSQLCatalog, line 551, in
manage_catalogFoundItems
NameError: global name 'time' is not defined (Also, an error occurred
while attempting to render the standard error message.)
--------------------------------
The problem code is
--------------------
obj_roles=obj_roles, obj_permission=obj_p
-> elapse = time.time()
-> c_elapse = time.clock()
words = 0
--------------------
Indeed the module doesn't import time at all and I could find any place
where it could be imported implicitly.
When I fixed that error (by adding import time), I was faced w/ another
missing import: urllib is used at line 578 but isn't imported.
I played w/ ZSQLCatalog-0.9-1mdk - derived RPM, but as I can see in CVS,
there's no corresponding fixes in trunk.