[Product-Developers] plone.formwidget.masterselect from svn trunk

Maurits van Rees m.van.rees at zestsoftware.nl
Tue Mar 13 12:50:09 UTC 2012


Op 13-03-12 13:30, SauZheR schreef:
> in main configure.zcml
>
>  1. [...]
>  2. <!-- Include our dependencies -->
>  3. <includeDependencies package="." />
>  4.
>
>  5. <adapter factory=".widget.MasterSelectFieldWidget" />
>  6. <adapter factory=".widget.MasterSelectBoolFieldWidget" />
>  7.
>
>  8. <browser:page
>  9.          for=".interfaces.IMasterSelectWidget"
> 10.          name="masterselect-jsonvalue"
> 11.          class=".widget.MasterSelectJSONValue"
> 12.          permission="cmf.AddPortalContent"
> 13.          />
>
>
> line 3.
> what is that? With this line my zope does not start at all. it reports
> "dict are not hashable". (python 2.7, plone4.1)
> If I comment out it, simply, all works fine. Product is installable,
> usable, enjoyable.

Python 2.7 is not officially supported, though anything that does not 
work with this version should be considered a bug worth reporting (and 
fixing).  I doubt that is the problem here though.

The includeDependencies line makes sure that the zcml of the 
dependencies defined in setup.py is loaded.  It would be strange if 
loading that zcml fails.  Do you have a full traceback from starting 
Zope in the foreground?  I guess there is an error in one of the 
dependencies; maybe you need a newer (or older) version.


>
> line 12.
> why addPortalContent is required to retrieve some data (often from
> public vocabulary)? I think this should be relaxed to a more comfortable
> zope2.View (or public?)

I have not looked at this package myself, but I guess this browser view 
is normally only used in an add or edit form and may make no sense for 
anonymous users or users with only a View permission.


-- 
Maurits van Rees: http://maurits.vanrees.org/
Zest Software: http://zestsoftware.nl



More information about the Product-Developers mailing list