Re: [Zope-CMF] Five:traversable and PortalContent

2005-11-30 Thread Brent Hendricks
On 11/30/05, Lennart Regebro <[EMAIL PROTECTED]> wrote:
> I think it *is* in the core now. I'm not sure it should be, though.

The only five:traversable declarations I see in the core now are for
the workflow and types tools.

> It's there to allow you to make views for objects, and I'm not at all
> sure it's a good idea to have that feature turned on for everything
> like that. It has caused me trouble earlier, I know that.

Right.  Clearly it messes something up, but I'm not sure what exactly.

So for folks working on CMF viewification, have you seen this problem?
Or do you declare traversable at some other level?

Brent
___
Zope-CMF maillist  -  Zope-CMF@lists.zope.org
http://mail.zope.org/mailman/listinfo/zope-cmf

See http://collector.zope.org/CMF for bug reports and feature requests


Re: [Zope-CMF] Five:traversable and PortalContent

2005-11-30 Thread Lennart Regebro
On 11/29/05, Brent Hendricks <[EMAIL PROTECTED]> wrote:
> When goldegg was first started, plone had a line like this in configure.zcml:
>
>  class="Products.CMFCore.PortalContent.PortalContent"
>   />
>
> I've noticed that this line causes failures in the CMFCore tests so
> I'm taking it out of plone.  If it's necessary it should probably go
> in CMFCore anyway

I think it *is* in the core now. I'm not sure it should be, though.
It's there to allow you to make views for objects, and I'm not at all
sure it's a good idea to have that feature turned on for everything
like that. It has caused me trouble earlier, I know that.

--
Lennart Regebro, Nuxeo http://www.nuxeo.com/
CPS Content Management http://www.cps-project.org/
___
Zope-CMF maillist  -  Zope-CMF@lists.zope.org
http://mail.zope.org/mailman/listinfo/zope-cmf

See http://collector.zope.org/CMF for bug reports and feature requests


[Zope-CMF] Five:traversable and PortalContent

2005-11-29 Thread Brent Hendricks
When goldegg was first started, plone had a line like this in configure.zcml:

  

I've noticed that this line causes failures in the CMFCore tests so
I'm taking it out of plone.  If it's necessary it should probably go
in CMFCore anyway, but I'm puzzled by the test failures.  On the trunk
are you marking PortalContent traversable in some other way?

Here's an example:

ERROR: test_Condition_PathExpression
(CMFCore.tests.test_ActionInformation.ActionInformationTests)
--
Traceback (most recent call last):
  File "/opt/instances/cmf1.6/Products/CMFCore/tests/test_ActionInformation.py",
line 312, in test_Condition_PathExpression
self.failUnless(ai.testCondition(ec))
  File "/opt/instances/cmf1.6/Products/CMFCore/ActionInformation.py",
line 236, in testCondition
return bool( self.condition(ec) )
  File "/opt/instances/cmf1.6/Products/CMFCore/Expression.py", line
44, in __call__
res = compiled(econtext)
  File "/opt/Zope-2.8/lib/python/Products/PageTemplates/Expressions.py",
line 185, in __call__
return self._eval(econtext)
  File "/opt/Zope-2.8/lib/python/Products/PageTemplates/Expressions.py",
line 173, in _eval
ob = self._subexprs[-1](econtext)
  File "/opt/Zope-2.8/lib/python/Products/PageTemplates/Expressions.py",
line 127, in _eval
ob = restrictedTraverse(ob, path, getSecurityManager())
  File "/opt/Zope-2.8/lib/python/Products/PageTemplates/Expressions.py",
line 286, in restrictedTraverse
o=t(REQUEST, name)
  File "/opt/instances/goldegg/Products/Five/traversable.py", line 58,
in __fallback_traverse__
raise AttributeError, name
AttributeError: test_script
___
Zope-CMF maillist  -  Zope-CMF@lists.zope.org
http://mail.zope.org/mailman/listinfo/zope-cmf

See http://collector.zope.org/CMF for bug reports and feature requests