Hi all,
On a current project, I've thrown out all Plone templates and put them back
as needed (templates provided by designer) which is working great, except
for the occasional odd error such as the following.
When trying to set editor preferences for the top level Zope user in Plone,
I get a tb which turns out to be due to the fact that a call to PAS returns
nothing:
{{{
Traceback (innermost last):
Module ZPublisher.Publish, line 119, in publish
Module ZPublisher.mapply, line 88, in mapply
Module Products.PDBDebugMode.runcall, line 70, in pdb_runcall
Module ZPublisher.Publish, line 42, in call_object
Module Products.CMFFormController.FSControllerPageTemplate, line 90, in
__call__
Module Products.CMFFormController.BaseControllerPageTemplate, line 28, in
_call
Module Products.CMFFormController.ControllerBase, line 231, in getNext
Module Products.CMFFormController.Actions.TraverseTo, line 38, in __call__
Module ZPublisher.mapply, line 88, in mapply
Module ZPublisher.Publish, line 42, in call_object
Module Products.CMFFormController.FSControllerPythonScript, line 104, in
__call__
Module Products.CMFFormController.Script, line 145, in __call__
Module Products.CMFCore.FSPythonScript, line 140, in __call__
Module Shared.DC.Scripts.Bindings, line 313, in __call__
Module Shared.DC.Scripts.Bindings, line 350, in _bindAndExec
Module Products.CMFCore.FSPythonScript, line 196, in _exec
Module None, line 30, in prefs_user_edit
- <FSControllerPythonScript at /Plone/prefs_user_edit>
- Line 30
Module AccessControl.ZopeGuards, line 350, in guarded_apply
Module AccessControl.ZopeGuards, line 372, in builtin_guarded_apply
Module <string>, line 3, in _facade
Module plone.protect.utils, line 43, in _curried
Module Products.CMFPlone.PloneTool, line 105, in setMemberProperties
AttributeError: 'NoneType' object has no attribute 'setProperties'
>
/Users/aclark/Developer/eggs/Plone-3.3.3-py2.4.egg/Products/CMFPlone/PloneTool.py(105)setMemberProperties()
-> user.setProperties(**properties)
(Pdb) l
100 def setMemberProperties(self, member, REQUEST=None,
**properties):
101 pas = getToolByName(self, 'acl_users')
102 if safe_hasattr(member, 'getId'):
103 member = member.getId()
104 user = pas.getUserById(member)
105 -> user.setProperties(**properties)
106
107 security.declarePublic('getSiteEncoding')
108 def getSiteEncoding(self):
109 """ Get the default_charset or fallback to utf8.
110
(Pdb) member
'admin'
(Pdb) user = pas.getUserById(member)
(Pdb)
}}}
If I switch to the Plone Default theme, everything works fine. Does this ring
any
bells for anyone?
I've added back the "important stuff" e.g.
{{{
<metal:page define-macro="master">
<metal:block define-slot="top_slot" />
<metal:block use-macro="here/global_defines/macros/defines" />
}}}
to main_template, and Plone otherwise works fine ;-)
Thanks for any thoughts,
Alex
---
Alex Clark · http://aclark.net
Practical Plone 3 · http://tinyurl.com/practical-plone
_______________________________________________
Product-Developers mailing list
[email protected]
http://lists.plone.org/mailman/listinfo/product-developers