Question

There is a grok.traversable() directive:

http://grok.zope.org/doc/current/reference/directives.html#grok-traversable

I'd like to use it like this:

class MultiLinguageContentListingHelper(grok.CodeView):
    """
    Builds JSON multilingual content out of Plone. 
    """

    grok.baseclass()
    grok.traversable("getLanguages")

    def getLanguages(self):

However, this does not seem to be in five.grok:

AttributeError: 'module' object has no attribute 'traversable'

I am missing some lines to connect dots here

  • Is it a problem of too old grok version

  • Is it a problem that five.grok does not support this directive

In the case of latter where to poke five.grok to make the support happen?

Was it helpful?

Solution

It's not supported based on that error message. You'll need to contact the grok mailing list (and through it, Sylvain Viollon, probably) to find out what to do get that kind of support.

You may be able to try to use it directly form whichever grokcore.* package it's defined in, e.g. grokcore.view (you'll need to check).

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top