Re: [Zope3-dev] Splitting package configuration

2007-05-25 Thread Stephan Richter
On Wednesday 23 May 2007 12:24, Fred Drake wrote:
> "Official story" doesn't mean a lot to me these days.  I think of
> individual ZCML files as interface points: someone might reasonably be
> using them directly (unless the filename starts with an underscore).

But you are describing the internal ZC thinking here, certainly not something 
that has been widely or publically communicated. There are very few people 
out there using eggs. Most download a release, create an instance and drop 
the add-on packages in there, some using SETUP.cfg and others 
creating/copying the slugs by hand. 

> > I hope it is avoidable with the above insight.
>
> Again, if you think there's an official story that involves
> *requiring* people to rely on those nasty slug files, you're deluding
> yourself.  We've always maintained that those are "convenience" (for
> some definition of "wouldn't you like to shoot yourself in the
> foot?").

But this is how the latest release and trunk works! All of my projects still 
work this way. Nowhere else is a different process documented.

Regards,
Stephan
-- 
Stephan Richter
CBU Physics & Chemistry (B.S.) / Tufts Physics (Ph.D. student)
Web2k - Web Software Design, Development and Training
___
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com



Re: [Zope3-dev] Splitting package configuration

2007-05-23 Thread Fred Drake

On 5/23/07, Stephan Richter <[EMAIL PROTECTED]> wrote:

Thinking about it more, it would actually be backward-compatible, since we
never released the packages in themselves but always as part of the Zope 3
bundle. Also, even the packages that are not hooked in via zope.app.zcmlfiles
are added via the automated SETUP.cfg stuff. At least this is the official
story right now. :-)


"Official story" doesn't mean a lot to me these days.  I think of
individual ZCML files as interface points: someone might reasonably be
using them directly (unless the filename starts with an underscore).


I hope it is avoidable with the above insight.


Again, if you think there's an official story that involves
*requiring* people to rely on those nasty slug files, you're deluding
yourself.  We've always maintained that those are "convenience" (for
some definition of "wouldn't you like to shoot yourself in the
foot?").


Really? That would be a pitty, because it would allow us to have one release
with the old and the new way, so the first people can migrate.


Would be a pity, yes, but it'll never happen if we keep changing it.


 -Fred

--
Fred L. Drake, Jr.
"Chaos is the score upon which reality is written." --Henry Miller
___
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com



Re: [Zope3-dev] Splitting package configuration

2007-05-23 Thread Stephan Richter
On Wednesday 23 May 2007 11:07, Fred Drake wrote:
> On 5/23/07, Stephan Richter <[EMAIL PROTECTED]> wrote:
> > This solution would not be fully backward-compatible with people
> > including package "configure.zcml" files manually. I think this is okay,
> > since people often do not even want the browser stuff.
>
> That's hard to predict; some do, some don't, I don't know where "most"
> happens to fall.

Thinking about it more, it would actually be backward-compatible, since we 
never released the packages in themselves but always as part of the Zope 3 
bundle. Also, even the packages that are not hooked in via zope.app.zcmlfiles 
are added via the automated SETUP.cfg stuff. At least this is the official 
story right now. :-)

> > A fully backward solution would be to put all the generic package
> > configuration in a new ZCML file and combine them both in
> > "configure.zcml". However, I find that solution very undesirable, so I
> > hope noone will like it either. :-)
>
> I don't like that, but I don't think it's avoidable.

I hope it is avoidable with the above insight.

> 3.4 is never going to be released, is it?  That might bother some
> people (though not me).

Really? That would be a pitty, because it would allow us to have one release 
with the old and the new way, so the first people can migrate.

Regards,
Stephan
-- 
Stephan Richter
CBU Physics & Chemistry (B.S.) / Tufts Physics (Ph.D. student)
Web2k - Web Software Design, Development and Training
___
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com



Re: [Zope3-dev] Splitting package configuration

2007-05-23 Thread Fred Drake

On 5/23/07, Stephan Richter <[EMAIL PROTECTED]> wrote:

This solution would not be fully backward-compatible with people including
package "configure.zcml" files manually. I think this is okay, since people
often do not even want the browser stuff.


That's hard to predict; some do, some don't, I don't know where "most"
happens to fall.


A fully backward solution would be to put all the generic package
configuration in a new ZCML file and combine them both in "configure.zcml".
However, I find that solution very undesirable, so I hope noone will like it
either. :-)


I don't like that, but I don't think it's avoidable.


I would like to get this change started as soon as possible to make it work
for Zope 3.4. If noone objects, I will start with this in a few days.


3.4 is never going to be released, is it?  That might bother some
people (though not me).


 -Fred

--
Fred L. Drake, Jr.
"Chaos is the score upon which reality is written." --Henry Miller
___
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com



Re: [Zope3-dev] Splitting package configuration

2007-05-23 Thread Bernd Dorn


On 23.05.2007, at 14:04, Stephan Richter wrote:


Hi everyone,

I built my first Zope 3 instance with buildout yesterday. After I  
got an
initial version working, I found it pretty lame to use  
"zope.app.zcmlfiles".
With "zope.app.zcmlfiles" I had 100 eggs without it 84 eggs (this  
is somewhat

project-specific.)

However, I had to add several unneeded dependencies, because the
main "configure.zcml" of a package usually also includes the
browser "configure.zcml". For example, I have a dependency
on "zope.app.form", just because "zope.app.securitypolicy" (and other
packages) create old-style forms.

In fact, I do not even use anything declared in  
"IDefaultBrowserLayer", so any
browser "configure.zcml" is totally overhead for in this case. In  
fact,
anyone creating a new skin from scratch will want to avoid the same  
overhead.




+1 on the zcml splitting

note that the eggs still will have the same dependencies in setup.py,  
so the packages will be installed.



I think the solution can be very simple and be effectively backward- 
compatible

for most cases:

1. Do not include the browser "configure.zcml" files in the
main "configure.zcml" of that package.

2.
(a) If the package has a SETUP.cfg and "package-configure.zcml",  
then add the

browser "configure.zcml" include to that "package-configure.zcml".

(b) If the package is currently loaded via "zope.app.zcmlfiles"'s
"configure.zcml", then we will add the browser "configure.zcml" there.

This solution would not be fully backward-compatible with people  
including
package "configure.zcml" files manually. I think this is okay,  
since people

often do not even want the browser stuff.

A fully backward solution would be to put all the generic package
configuration in a new ZCML file and combine them both in  
"configure.zcml".
However, I find that solution very undesirable, so I hope noone  
will like it

either. :-)

I would like to get this change started as soon as possible to make  
it work

for Zope 3.4. If noone objects, I will start with this in a few days.

Regards,
Stephan
--
Stephan Richter
CBU Physics & Chemistry (B.S.) / Tufts Physics (Ph.D. student)
Web2k - Web Software Design, Development and Training
___
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/bernd.dorn% 
40lovelysystems.com




___
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com



[Zope3-dev] Splitting package configuration

2007-05-23 Thread Stephan Richter
Hi everyone, 

I built my first Zope 3 instance with buildout yesterday. After I got an 
initial version working, I found it pretty lame to use "zope.app.zcmlfiles". 
With "zope.app.zcmlfiles" I had 100 eggs without it 84 eggs (this is somewhat 
project-specific.)

However, I had to add several unneeded dependencies, because the 
main "configure.zcml" of a package usually also includes the 
browser "configure.zcml". For example, I have a dependency 
on "zope.app.form", just because "zope.app.securitypolicy" (and other 
packages) create old-style forms. 

In fact, I do not even use anything declared in "IDefaultBrowserLayer", so any 
browser "configure.zcml" is totally overhead for in this case. In fact, 
anyone creating a new skin from scratch will want to avoid the same overhead.

I think the solution can be very simple and be effectively backward-compatible 
for most cases:

1. Do not include the browser "configure.zcml" files in the 
main "configure.zcml" of that package.

2. 
(a) If the package has a SETUP.cfg and "package-configure.zcml", then add the 
browser "configure.zcml" include to that "package-configure.zcml".

(b) If the package is currently loaded via "zope.app.zcmlfiles"'s
"configure.zcml", then we will add the browser "configure.zcml" there.

This solution would not be fully backward-compatible with people including 
package "configure.zcml" files manually. I think this is okay, since people 
often do not even want the browser stuff.

A fully backward solution would be to put all the generic package 
configuration in a new ZCML file and combine them both in "configure.zcml". 
However, I find that solution very undesirable, so I hope noone will like it 
either. :-)

I would like to get this change started as soon as possible to make it work 
for Zope 3.4. If noone objects, I will start with this in a few days.

Regards,
Stephan
-- 
Stephan Richter
CBU Physics & Chemistry (B.S.) / Tufts Physics (Ph.D. student)
Web2k - Web Software Design, Development and Training
___
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com