[Zope3-dev] Re: Packaging pre-proposal/notes

Stephan Richter srichter at cosmos.phy.tufts.edu
Tue Feb 17 13:10:12 EST 2004


On Tuesday 17 February 2004 08:08, Philipp von Weitershausen wrote:
> Stephan Richter wrote:
> > The reason we suggested folder and folder_web in the first place was to
> > make it easier to develop new UIs. And this in turn was born from the
> > problem that it was not easy for us to deactivate the browser ZCML in a
> > package. Therefore, I would really like to go back to
> >
> > folder
> > folder/browser
>
> It is what we have now and we have said more than once that we don't
> like it, because:

Well, this is *not* what we have right now. We have

folder
browser/folder
interfaces/folder

and I suggest to go back to 

folder
folder/browser
folder/interfaces (if the interfaces are fairly locally applicable)

Also, what I am saying is that the new solutions we are thinking of are in my 
opinion so bad, that this solution looks attractive again.

> a) It would making browser code optional harder. When you install
> 'folder', you get the browser junk with it, no matter whether you want
> it or not.

No, here you mix package structure with distribution. Surely I can have 
folder-1.0.tgz and folder-browser-1.0.tgz and still get the directory 
structure above. The only thing we would need to change would be to not 
include the browser configuration from within folder, but separate them:

<include package="folder"/>
<include package="folder.browser"/>

> b) It doesn't emphasize separation of application and browser code enough.

How does it not. It's a separate package... All what the hierarchy says is 
that this browser package belongs to folder, which is very sensible. As was 
pointed out in other mails, package structure does not have to equal 
distribution structure. I am still completely for the idea of having many 
small packages with dependencies.

> c) It does not flatten the hierarchy enough. We will end up with browser
> subpackages again.

Ok, but: So what? Originally we had some goals in mind when saying we want to 
flatten the hierarchy:

1. Make zope.app more transparent. This is still possible with this 
suggestion.

2. Make it easier to package. I just showed that it would be equally hard or 
easy either way.

3. Separate presentation from content. I think this is still the case; just 
because a package lives in another one, does not mean it merged with its 
parent. Even better, it does not make sense to install folder-browser-1.0 if 
you do not have folder-1.0.

> What we really want is something like "separate but close". Being
> increasingly sceptical of my own suggestion, I think Jim's concept is
> the closest one to that doctrine, even though I still dislike the usage
> of the underscore and not being able to make proper use of Python
> namespaces. In that respect, I have great sympathy for Garret's and
> Roger's opinion. I draw a different conclusion, though.

I think my solution follows the "separate but close" doctrine too and still 
makes proper use of Python namespaces.

> I think that is not nearly as clear as simply adding or removing a line
> from products.zcml or whereever the numerous packages in zope.app will
> be configured from.
>
> Where would this stanza of ZCML you're suggesting be? In the global
> config file (e.g. products.zcml)? Or in the
> srichter.folder/configure.zcml? Neither place looks "right"... :)

I agree with Martijn's response on this question.

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