[Zope3-dev] Voting on Schema design

R. David Murray bitz@bitdance.com
Mon, 15 Jul 2002 10:26:28 -0400 (EDT)


On Mon, 15 Jul 2002, Martijn Faassen wrote:
>   * Python uses these short names, and is moving towards that more and
>     more in recent releases, away from types.StringType and the like.

+1 on sticking with python names for Fields that specify python data types.
Anything else just feels...weird.  And the use cases clearly call
for Fields that specify python data types (as well as, as Martijn said,
other data types later).

> > 2. I think the Schema package should be in lib/python/Zope and not lib/python.
> That's easy to decide; Jim and I at the sprint already agreed it should
> be there, but since I'd placed them in lib/python already, we decided to
> forgo moving it for the moment. Why is a vote necessary here? Do you think
[...]
> Related to the dependency issue; one of the use cases of some people
> (you, R.D.Murray) appears to be that we want to be able to use the Schema
> code outside Zope, and therefore we need to minimize the dependencies
> on Zope. Does this mean that Schema can't depend, for instance, on
> ComponentArchitecture? (for instance your adapter-like validators seem
> to want this).

Um, I don't get why you'd want to move it into Zope.  Why does it
belong anywhere other than in Interfaces?  If the consensus is that
it would overcomplexify Interfaces, then I'd like to see it stay
at the same level that Interfaces is at (ie: in lib/python where
it is now).  This is related to my belief that Schemas have significant
utility outside of Zope.  While having a package I want to use
outside of Zope be in a Zope master-package isn't a big deal in
general, I think Schemas in particular belong at the same level as
Interfaces if they aren't part of the Interfaces package, and I
don't think anyone is calling for Interfaces to be moved into Zope.

As for the Adapter dependency, what I'd like to see is the
implementation of Phillip Eby's proposal to make the ItoIRegistry
part of Interfaces.  I haven't looked into how exactly this would
work in practice, but it seems like if there were then a "standard"
getAdapter Interface that anybody using ItoIRegistry would implement,
Schemas could use adapters and still be Zope independent <grin>.

I think Interfaces and getAdapter may be one of *the* most important
technologies Zope3 has invented, and I'd like to see it made more
widely usable in the Python community.

--RDM