Discussion:
[Erp5-dev] Strange error.
Mauro Ziliani
2008-01-11 10:26:16 UTC
Permalink
Hi all.
I have installed erp5 on debian etch.
When I start the instance Zope tell me that some package is obsolete.
But finally I can manage the requests (as I read).
When I create a new ERP5 Site by ZMI I reach the following error.


Site Error

An error was encountered while publishing this resource.

*Error Type: ImportError*
*Error Value: cannot import name WeakSet*

------------------------------------------------------------------------

Troubleshooting Suggestions

* The URL may be incorrect.
* The parameters passed to this resource may be incorrect.
* A resource that this resource relies on may be encountering an error.

For more detailed information about the error, please refer to the error
log.

If the error persists please contact the site maintainer. Thank you for
your patience.



And in the error_log I see

Traceback (innermost last):
Module ZPublisher.Publish, line 101, in publish
099 | missing_name,
100 | dont_publish_class,
101>| request, bind=1)
102 |
103 | if result is not response:

Module ZPublisher.mapply, line 88, in mapply
086 |
087 | args=tuple(args)
088>| if debug is not None: return debug(object,args,context)
089 | else: return object(*args)

Module ZPublisher.Publish, line 39, in call_object
037 |
038 |def call_object(object, args, request):
039>| result=apply(object,args) # Type s<cr> to step into published object.
040 | return result
041 |

Module Products.ERP5.ERP5Site, line 93, in manage_addERP5Site
091 | create_activities=create_activities,
092 | light_install=light_install,
093>| reindex=reindex)
094 | gen.setupDefaultProperties(p,
095 | title,

Module Products.ERP5.ERP5Site, line 1116, in create
1114 | p._setProperty('management_page_charset', 'UTF-8', 'string')
1115 | self.setup(p, create_userfolder, create_activities=create_activities,
1116>| reindex=reindex, **kw)
1117 | return p
1118 |

Module Products.ERP5.ERP5Site, line 1543, in setup
1541 |
1542 | if not update:
1543>| self.setupERP5Core(p,**kw)
1544 |
1545 | # Make sure the cache is initialized

Module Products.ERP5.ERP5Site, line 1587, in setupERP5Core
1585 | id = template_tool.generateNewId()
1586 | template_tool.download(template, id=id)
1587>| template_tool[id].install(**kw)

Module Products.ERP5Type.Base, line 211, in __call__
209 |
210 | # Compute expected result
211>| result = apply(self.__dict__['_m'], (instance,) + args, kw)
212 |
213 | # Change the state of statefull workflows

Module Products.ERP5Type.Document.BusinessTemplate, line 4481, in install
4479 | For install based on paramaters provided in **kw
4480 | """
4481>| return self._install(**kw)
4482 |
4483 | install = WorkflowMethod(install)

Module Products.ERP5Type.Document.BusinessTemplate, line 4412, in _install
4410 | item = getattr(self, item_name, None)
4411 | if item is not None:
4412>| item.install(local_configuration, force=force, object_to_update=object_to_update, trashbin=trashbin)
4413 |
4414 | # update catalog if necessary

Module Products.ERP5Type.Document.BusinessTemplate, line 731, in install
729 | obj = obj._getCopy(container)
730 | try:
731>| container._setObject(object_id, obj)
732 | except AttributeError:
733 | LOG("BT, install", 0, object_id)

Module OFS.ObjectManager, line 276, in _setObject
274 | object.manage_setLocalRoles(userid, ['Owner'])
275 |
276>| object.manage_afterAdd(object, self)
277 | return id
278 |

Module Products.ERP5Type.CopySupport, line 318, in manage_afterAdd
316 | #LOG("After Add ",0, "id:%s containes:%s" % (str(item.id), str(container.id)))
317 | if getattr(self, 'isIndexable', 0):
318>| self.reindexObject()
319 | if getattr(self, 'isIndexable', 1):
320 | self.__recurse('manage_afterAdd', item, container)

Module Products.ERP5Type.Core.Folder, line 1055, in reindexObject
1053 | """Fixes the hierarchy structure (use of Base class)
1054 | """
1055>| return Base.reindexObject(self, *args, **kw)
1056 |
1057 | security.declareProtected(Permissions.ModifyPortalContent,

Module Products.ERP5Type.Base, line 2678, in reindexObject
2676 | args / kw required since we must follow API
2677 | """
2678>| self._reindexObject(*args, **kw)
2679 |
2680 | def _reindexObject(self, activate_kw=None, **kw):

Module Products.ERP5Type.Base, line 2702, in _reindexObject
2700 | self.activate(group_method_id='portal_catalog/catalogObjectList',
2701 | alternate_method_id='alternateReindexObject',
2702>| group_id=group_id,
2703 | **activate_kw).immediateReindexObject(**kw)
2704 |

Module Products.CMFActivity.ActivityTool, line 278, in __call__
276 | def __call__(self, *args, **kw):
277 | m = Message(self.__passive_self, self.__active_process, self.__kw, self.__method_id, args, kw)
278>| activity_dict[self.__activity].queueMessage(self.__passive_self.portal_activities, m)
279 |
280 |allow_class(Method)

Module Products.CMFActivity.Activity.Queue, line 129, in queueMessage
127 |
128 | def queueMessage(self, activity_tool, m):
129>| activity_tool.deferredQueueMessage(self, m)
130 |
131 | def deleteMessage(self, activity_tool, m):

Module Products.CMFActivity.ActivityTool, line 737, in deferredQueueMessage
735 | def deferredQueueMessage(self, activity, message):
736 | activity_buffer = self.getActivityBuffer()
737>| activity_buffer.deferredQueueMessage(self, activity, message)
738 |
739 | def deferredDeleteMessage(self, activity, message):

Module Products.CMFActivity.ActivityBuffer, line 151, in deferredQueueMessage
149 |
150 | def deferredQueueMessage(self, activity_tool, activity, message):
151>| self._register(activity_tool)
152 | # Activity is called to prevent queuing some messages (useful for example
153 | # to prevent reindexing objects multiple times)

Module Products.CMFActivity.ActivityBuffer, line 73, in _register
071 |
072 | def _register(self, activity_tool):
073>| self._beginAndHook(activity_tool)
074 | TM._register(self)
075 |

Module Products.CMFActivity.ActivityBuffer, line 90, in _beginAndHook
088 | # In Zope 2.8 (ZODB 3.4), use beforeCommitHook instead of
089 | # patching Trasaction.
090>| transaction = get_transaction()
091 | try:
092 | transaction.beforeCommitHook(self.tpc_prepare, transaction, activity_tool=activity_tool)

Module transaction._manager, line 148, in get
146 | synchs = self._synchs.get(tid)
147 | if synchs is None:
148>| from ZODB.utils import WeakSet
149 | synchs = self._synchs[tid] = WeakSet()
150 | txn = self._txns[tid] = Transaction(synchs, self)
ImportError: cannot import name WeakSet




-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.tiolive.com/pipermail/erp5-dev/attachments/20080111/1588f565/attachment.htm>
Łukasz Nowak
2008-01-11 15:23:52 UTC
Permalink
Hello,

On 2008-01-11, 11:26:16
Post by Mauro Ziliani
Hi all.
I have installed erp5 on debian etch.
When I start the instance Zope tell me that some package is obsolete.
But finally I can manage the requests (as I read).
When I create a new ERP5 Site by ZMI I reach the following error.
Site Error
An error was encountered while publishing this resource.
*Error Type: ImportError*
*Error Value: cannot import name WeakSet*
(...)

Did you installed python-zodb package? Uninstall it and try again.

It helped me, if you confirm it please update
http://www.erp5.org/TroubleShootingFaq

Regards,
Luke
--
?ukasz Nowak R&D Ventis http://www.ventis.com.pl/
tel: +48 32 768 16 85 fax: +48 32 392 10 61
``Use the Source, Luke...'' I am only craftsman.
Loading...