[Zope3-dev] Schema and Widget Update

Stephan Richter srichter at cosmos.phy.tufts.edu
Thu Apr 29 08:18:31 EDT 2004


Fixed in CVS.

Regards,
Stephan

On Tuesday 27 April 2004 06:50, Eckart Hertzler wrote:
> On Sunday 25 April 2004 01:37, Stephan Richter is believed to have said:
> > Hi everyone,
> >
> > I just checked in a whole lot of code that changes significantly how
> > fields and forms work. All enumerated and vocabulary fields and widgets
> > are gone and they have been replaced by Choice and Sequence as well as
> > their corresponding widgets.
> >
> > This was a lot of hairy work, and I would not be surprised if we find
> > some hickups, so I checked the directly affected pages and wrote a bunch
> > of unit tests to verify the correct functioning.
>
> And here is a hickup:
>
> Trying to edit a wikipage results in this :
>
> Fehlertyp: exceptions.TypeError
>
>
> Fehlerobjekt: __init__() takes exactly 4 arguments (3 given)
>
>       File "/home/hertzler/zope/Zope3/src/zope/publisher/publish.py", line
> 134, in publish
>     object = request.traverse(object)
>
>       File "/home/hertzler/zope/Zope3/src/zope/publisher/browser.py", line
> 496, in traverse
>     ob = super(BrowserRequest, self).traverse(object)
>
>       File "/home/hertzler/zope/Zope3/src/zope/publisher/http.py", line
> 416, in traverse
>     ob = super(HTTPRequest, self).traverse(object)
>
>       File "/home/hertzler/zope/Zope3/src/zope/publisher/base.py", line
> 256, in traverse
>     subobject = publication.traverseName(
>
>       File
> "/home/hertzler/zope/Zope3/src/zope/app/publication/publicationtraverse.py"
>, line 42, in traverseName
>     ob2 = namespaceLookup(ns, nm, ob, request)
>
>       File
> "/home/hertzler/zope/Zope3/src/zope/app/traversing/namespace.py", line 104,
> in namespaceLookup
>     return traverser.traverse(name, ())
>
>       File
> "/home/hertzler/zope/Zope3/src/zope/app/traversing/namespace.py", line 340,
> in traverse
>     view = zapi.queryView(self.context, name, self.request)
>
>       File "/home/hertzler/zope/Zope3/src/zope/app/component/hooks.py",
> line 70, in queryView
>     providing=providing)
>
>       File "/home/hertzler/zope/Zope3/src/zope/component/presentation.py",
> line 403, in queryView
>     r = layer.queryMultiAdapter(objects, providing, name)
>
>       File "/home/hertzler/zope/Zope3/src/zope/component/presentation.py",
> line 483, in queryMultiAdapter
>     return factory(*objects)
>
>       File
> "/home/hertzler/zope/Zope3/src/zope/app/form/browser/editview.py", line 60,
> in __init__
>     self._setUpWidgets()
>
>       File
> "/home/hertzler/zope/Zope3/src/zope/app/form/browser/editview.py", line 70,
> in _setUpWidgets
>     names=self.fieldNames)
>
>       File "/home/hertzler/zope/Zope3/src/zope/app/form/utility.py", line
> 161, in setUpEditWidgets
>     names, context, IDisplayWidget, IInputWidget)
>
>       File "/home/hertzler/zope/Zope3/src/zope/app/form/utility.py", line
> 193, in _setUpFormWidgets
>     ignoreStickyValues, context)
>
>       File "/home/hertzler/zope/Zope3/src/zope/app/form/utility.py", line
> 102, in setUpWidget
>     widget = widget(field.bind(context), view.request)
>
>       File "/home/hertzler/zope/Zope3/src/zope/app/form/__init__.py", line
> 83, in __call__
>     instance = self._widget_factory(*args)
>
>
> it seems the widget factory expects a vocabulary but doesn't gets one..
>
> > Gary, this one is for you: I have only commented out the tests in
> > complexsample, since it was too hairy for me to get into. Since you have
> > to adjust your code anyways for the customer, I think you are the better
> > person to fix it anyways. :-)
> >
> > If you experience any troubles, please let me know.
> >
> > Regards,
> > Stephan

-- 
Stephan Richter
CBU Physics & Chemistry (B.S.) / Tufts Physics (Ph.D. student)
Web2k - Web Software Design, Development and Training



More information about the Zope3-dev mailing list