[Twisted-Python] viewStack breakage
typo at soniq.net
Thu Oct 31 09:48:17 EST 2002
hey, thanks for fixing the caching bug that quickly!
i think something else broke with your last few commits though:
this debug output is from getNodeView for a GET request, with no controllers
working. i have a wvfactory_DetailLink in sam.web.serverlist.View, which the
viewStack finds without problems:
31/10/2002 15:41 [*samclient*] [<twisted.web.woven.widgets.KeyedList instance at 0x83c17e4>, <twisted.web.woven.widgets.DefaultWidget instance at 0x83e6674>, <twisted.web.woven.widgets.DefaultWidget instance at 0x83e45ac>, <sam.web.serverlist.View instance at 0x83ae814>, <module 'twisted.web.woven.widgets' from '/home/paul/Twisted/twisted/web/woven/widgets.pyc'>]
now when i submit data to my controller, i get a different viewStack
exceptions.NotImplementedError: You specified view name DetailLink on a node, but no factory_DetailLink method was found in [<twisted.web.woven.widgets.DefaultWidget instance at 0x840963c>, <twisted.web.woven.widgets.KeyedList instance at 0x83db2bc>, <module 'twisted.web.woven.widgets' from '/home/paul/Twisted/twisted/web/woven/widgets.pyc'>].
the relevant xhtml snippet for this is:
<ul model="root/inventory" view="KeyedList">
<li id="emptyList">No Servers defined</li>
<a view="DetailLink" model="name">
<span view="Text" model="name" /></a>
root is a dictionary in my serverlist.Model, which has serverlist.View
registered as View.
inventory is a Dictionary like class, which has registered for a
DictionaryModel Wrapper with components.
as inventory is only a virtual model, imho the parent's view should
propagate down to it's viewStack, which seems to work, unless a controller
what's needed to fix this? do i need to make inventory and/or root
a real model and register a view for it ?
More information about the Twisted-Python