[Grok-dev] re gistering vocabulary
jmichiel at yahoo.com
Mon May 9 08:17:53 EDT 2011
Brilliant! adding 'zope.app.schema' did the trick!
Strange that a .app. package is still needed...
I tried with a clean 1.4 project, and had the same problem! Adding
'zope.app.schema' fixed it there, too...
Sebastian Ware wrote:
> The only difference I see is that you name your vocab with a string
> grok.name('Time of Day')
> and I use a unicode string
> oh, we have also added
> to install_requires in setup.py, I have a vague memory that this was
> Mvh Sebastian
> 9 maj 2011 kl. 11.03 skrev Jeroen Michiel:
>> I have the exact same issue while trying to upgrade a v1.1 project to
>> I create my vocabularies like this:
>> class TimeOfDayVocabulary(grok.GlobalUtility):
>> grok.name('Time of Day')
>> def __call__(self, context):
>> return SimpleVocabulary.fromValues([u'Day', u'Night', u'Dusk',
>> but each time a schema field tries to access them, I get a
>> VocabularyRegistryError: unknown vocabulary: u'Time of Day'
>> I'll try to revert to v1.3 and see if that makes any difference...
>> View this message in context:
>> Sent from the Grok mailing list archive at Nabble.com.
>> Grok-dev mailing list
>> Grok-dev at zope.org
> Grok-dev mailing list
> Grok-dev at zope.org
View this message in context: http://old.nabble.com/registering-vocabulary-tp31388474p31576240.html
Sent from the Grok mailing list archive at Nabble.com.
More information about the Grok-dev