Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Chris Withers
Shane Hathaway wrote: FWIW, I still hate ZCML for the following reasons: Everyone seems to agree on the direction suggested here: http://www.z3lab.org/sections/blogs/philipp-weitershausen/2005_12_14_zcml-needs-to-do-less Indeed, while I strongly agree with all of this, I think it's orthagon

Re: [Zope3-dev] Re: RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Dario Lopez-Kästen
Andreas Jung wrote: --On 23. Januar 2006 15:22:27 -0500 Andrew Sawyers <[EMAIL PROTECTED]> wrote: On Mon, 2006-01-23 at 18:51 +0100, Andreas Jung wrote: This separation is artificial. I've never seen a single Zope installation where a system administrator had to care about Zope configura

Re: [Zope3-dev] Re: RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Martijn Faassen
Andrew Sawyers wrote: 1. On Mon, 2006-01-23 at 18:29 +0100, Martijn Faassen wrote: [snip] And the intended audience of ZCML is a very different audience - developers versus sysadmins. I'd have to say, I belived quite the opposite. There are specific references to Admins being part of t

Re: [Zope3-dev] RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Chris Withers
Fred Drake wrote: On 1/21/06, Jim Fulton <[EMAIL PROTECTED]> wrote: are really attributes of foo. In ZCML, this might have been: Except this breaks down in the case of ZConfig elements, which allow configuration like this: x = 1 x = 2 y = 3 Yes, but both ZCML and T

Re: [Zope3-dev] RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Chris Withers
Jim Fulton wrote: Maybe. My thought that this might be handled by cheating in the sax events. (Or maybe we shouldn't exactly do sax events.) In the event that says "here's a tag named 'foo'", we'd provide a list for the value of x. Or we could do separate events for each option. I think we def

Re: [Zope3-dev] RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Chris Withers
Fred Drake wrote: On 1/23/06, Chris Withers <[EMAIL PROTECTED]> wrote: As I said earlier, I think XML is wrong for configuration for exactly this kind of reason... element-based is right for this type of config, it's why Apache uses, it's why Zope 2 uses it, and it's why Zope 3 uses it for the

Re: [Zope3-dev] Re: RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Chris Withers
Martin Aspeli wrote: No, I heard you the first time. But whilst zope.conf has been around for ages, it has not been used for the purpose that ZCML is now used. Really? I thought ZCML was used for configuration of a web application/server. .conf has been used exactly that with Apache for a lon

Re: [Zope3-dev] Re: RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Chris Withers
Martin Aspeli wrote: Except ZConfig on/off switches are very easy to understand just by reading the zope.conf file. That doesn't mean that same syntax would make managing something as complex as the type of wiring ZCML is currently used for any clearer, though. No, but that's the realm of Ph

[Zope3-dev] Re: RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Chris Withers
Max M wrote: Personally I abhor these configuration languages. I can never figure out what all the options are, and I allways suspect that I am missing something clever in some undocumented cornercase somewhere. Well, ZCML is already self documenting, as far as I can see. Zope.conf would als

Re: [Zope3-dev] Re: RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Sidnei da Silva
On Tue, Jan 24, 2006 at 10:13:33AM +, Chris Withers wrote: | Zope 3 then introduced ZCML, which | no other web server on the planet uses ;-) I think you are mistaken. If ZCML is a variant of XML, then Zope 3 is not alone. I've been told that IIS 7 does use XML for it's configuration. -- Sid

Re: [Zope3-dev] Re: RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Chris Withers
Martijn Faassen wrote: Sure, but it's not my point. I don't think sysadmins, familiar with Apache configuration syntax, are the audience for ZCML. Developers are. Therefore, an important benefit of ZConfig syntax, familiarity from Apache, goes away in case of ZCML. Well, I can only speak for

Re: [Zope3-dev] ZCML bad ;-)

2006-01-24 Thread Chris Withers
Stephan Richter wrote: I'll note that I commonly make browser the default namespace in browser packages. And _I'll_ note that it's one of the things in your book that threw me... I had to do a double take to figure out where all these "new" directives had come from when I eventually noticed

Re: [Zope3-dev] ZCML bad ;-)

2006-01-24 Thread Chris Withers
Gary Poster wrote: FWIW, me too. I'm no XML guru (as Fred will attest ;-) ) but reading the namespaces on an XML file seems like basic XML procedure. Well, the reading of them is the lesser of my two complaints... I find it irksome to have to type them at the top of ever file. Is there no

Re: [Zope3-dev] ZCML bad ;-)

2006-01-24 Thread Fred Drake
On 1/24/06, Chris Withers <[EMAIL PROTECTED]> wrote: > I find it irksome to have to type them at the top of ever file. Is there > no way that they could be pre-bound in the XML parser? That way you'd > only need to inlcude them if you wanted to rebind them... Even if we could avoid it at a technic

Re: [Zope3-dev] ZCML bad ;-)

2006-01-24 Thread Chris Withers
Fred Drake wrote: Even if we could avoid it at a technical level, it means that what we're reading is no longer XML. One of the desires with ZCML was to not invent everything from scratch. So, *if* we're using XML, we need to use it as defined, otherwise it *isn't* XML. Yay.. bow down and w

[Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Philipp von Weitershausen
Fred Drake wrote: >>I find it irksome to have to type them at the top of ever file. Is there >>no way that they could be pre-bound in the XML parser? That way you'd >>only need to inlcude them if you wanted to rebind them... > > Even if we could avoid it at a technical level, it means that what >

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Shane Hathaway
Philipp von Weitershausen wrote: However, I think one namespace for ZCML is enough. +1 Shane ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Chris Withers
Shane Hathaway wrote: Philipp von Weitershausen wrote: However, I think one namespace for ZCML is enough. +1 +1 ;-) (and if we can get it down to one, we don't have to specify it at the top of the file... yay!) cheers, Chris -- Simplistix - Content Management, Zope & Python Consulting

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread cstrong
> Shane Hathaway wrote: >> Philipp von Weitershausen wrote: >> >>> However, I think one namespace for ZCML is enough. >> >> +1 Big +1 to all of Philipp's suggestions. I have a fair amount of experience with Zope2 and am learning Zope3...but with half an eye at Ruby on Rails and Spring/Hibernate.

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Fred Drake
On 1/24/06, Chris Withers <[EMAIL PROTECTED]> wrote: > Shane Hathaway wrote: > > Philipp von Weitershausen wrote: > > > >> However, I think one namespace for ZCML is enough. Are you sure? Perhaps it's reasonable to use a single namespace for all the ZCML directives defined as part of the Zope 3 r

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Benji York
[EMAIL PROTECTED] wrote: > I like generating documentation directly from source. > Namespaces provide a nice way to do that with XML files via XSLT, while > still enabling RelaxNG schema validation, etc. > > foo > >The foo directive indicates that the bar setting should be wombat. >

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Stephan Richter
On Tuesday 24 January 2006 11:29, Fred Drake wrote: > > >> However, I think one namespace for ZCML is enough. > > Are you sure? > > Perhaps it's reasonable to use a single namespace for all the ZCML > directives defined as part of the Zope 3 release.  What about > third-party directives?  Are you s

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Shane Hathaway
Fred Drake wrote: On 1/24/06, Chris Withers <[EMAIL PROTECTED]> wrote: Shane Hathaway wrote: Philipp von Weitershausen wrote: However, I think one namespace for ZCML is enough. Are you sure? Perhaps it's reasonable to use a single namespace for all the ZCML directives defined as part o

[Zope3-dev] zope.schema: defaults for non-immutables... questions

2006-01-24 Thread Shaun Cutts
It would seem that the current default mechanism is poorly suited to providing default values for non-immutables. For example:   class IBar( Interface ):       a = Object( schema = IFoo, default = Foo() )     But if a “Foo” is not immutable this doesn’t make sense. (In my case, I wan

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread cstrong
That's a fair question. This is a pattern I have learned by using Docbook 5.0, which is another one of those _lets_rewrite_an_established_technology_to_address_longstanding_issues_ releases. Norm uses the RelaxNG annotations namespace[1]. I like the design principle RelaxNG uses for namespaces:

Re: [Zope3-dev] zope.schema: defaults for non-immutables... questions

2006-01-24 Thread Shane Hathaway
Shaun Cutts wrote: It would seem that the current default mechanism is poorly suited to providing default values for non-immutables. For example: "Mutable" is a better way to say "non-immutable". :-) class IBar( Interface ): a = Object( schema = IFoo, default = Foo() ) But if a “Foo” is

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Gary Poster
On Jan 24, 2006, at 12:22 PM, Shane Hathaway wrote: Fred Drake wrote: On 1/24/06, Chris Withers <[EMAIL PROTECTED]> wrote: Shane Hathaway wrote: Philipp von Weitershausen wrote: However, I think one namespace for ZCML is enough. Are you sure? Perhaps it's reasonable to use a single names

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Christian Lück
Shane Hathaway wrote: > Fred Drake wrote: > >> On 1/24/06, Chris Withers <[EMAIL PROTECTED]> wrote: >> >>> Shane Hathaway wrote: >>> Philipp von Weitershausen wrote: > However, I think one namespace for ZCML is enough. >> >> >> >> Are you sure? >> >> Perhaps it's reasonable to u

Re: [Zope3-dev] ZCML bad ;-)

2006-01-24 Thread Jeff Shell
On 1/24/06, Chris Withers <[EMAIL PROTECTED]> wrote: > Gary Poster wrote: > > > > FWIW, me too. I'm no XML guru (as Fred will attest ;-) ) but reading > > the namespaces on an XML file seems like basic XML procedure. > > Well, the reading of them is the lesser of my two complaints... > > I find it

[Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Alexander Limi
On Tue, 24 Jan 2006 11:10:29 -0800, Jeff Shell <[EMAIL PROTECTED]> wrote: It's like those damned imports in Python. Why can't everything just be available in one big honkin' namespace automatically? I believe you mis-spelled "acquisition". *ducks* ;) --

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Shane Hathaway
Alexander Limi wrote: On Tue, 24 Jan 2006 11:10:29 -0800, Jeff Shell <[EMAIL PROTECTED]> wrote: It's like those damned imports in Python. Why can't everything just be available in one big honkin' namespace automatically? I believe you mis-spelled "acquisition". Acquisition is extensibili

RE: [Zope3-dev] zope.schema: defaults for non-immutables... questions

2006-01-24 Thread Shaun Cutts
Shane, I considered 'default_factory' myself It seems good, but it complicates the logic internally. For one thing, logically, we'd have to also have 'missing_value_default' (unless we decree that missing values have to be not-non-immutable, ah... immutable). A further thought on where to put

[Zope3-dev] doctest: Get type of object

2006-01-24 Thread Florian Lindner
Hello, I'm currently writing a test in a README.txt and I want to make sure that returned object a is of type zope.app.x. How can I test that? Thanks, Florian ___ Zope3-dev mailing list Zope3-dev@zope.org Unsub: http://mail.zope.org/mailman/options/zop

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Chris Withers
Fred Drake wrote: Are you sure? Perhaps it's reasonable to use a single namespace for all the ZCML directives defined as part of the Zope 3 release. What about third-party directives? Are you saying we don't need to worry about introducing names that conflict with third-party names we don't k

Re: [Zope3-dev] RFC: ZConfig and other formats for ZCML

2006-01-24 Thread ksmith99 (sent by Nabble.com)
Jim Fulton wrote: Martijn Faassen wrote: > Shane Hathaway wrote: > >> Jim Fulton wrote: >> >>> See: >>> >>>   http://dev.zope.org/Zope3/ZConfigAndOtherFormatsForZCML >>> >>> Comments and volunteers welcome. >> >> >> >> I like this proposal.  It is likely to reduce the total amount of code. >> >>

[Zope3-dev] Re: Re: RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Martin Aspeli
On Tue, 24 Jan 2006 10:16:13 -, Chris Withers <[EMAIL PROTECTED]> wrote: Commercial development tools typically have pretty decent XML support, and if you were to write e.g. a ZCML editor as an Eclipse plug in, being able to rely on existing XML components would be much easier. Develope

Re: [Zope3-dev] RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Dieter Maurer
Martijn Faassen wrote at 2006-1-23 18:27 +0100: > ... >For one, ZConfig is a >syntax not very well known, even granting its similarity to the Apache >configuration language, while XML is very well known. Come on: The only "syntactic" part of "ZConfig" is: there are keys with values and sect

Re: [Zope3-dev] RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Dieter Maurer
Fred Drake wrote at 2006-1-23 09:56 -0500: >On 1/23/06, Chris Withers <[EMAIL PROTECTED]> wrote: >> As I said earlier, I think XML is wrong for configuration for exactly >> this kind of reason... element-based is right for this type of config, >> it's why Apache uses, it's why Zope 2 uses it, and i

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Shane Hathaway
Christian Lück wrote: From a lerners point of view (for example me) the thematic organization is a pro too: The z3 beginner will probably need the 'zope' and 'browser' namespaces at first. Browsing apidoc zcml namespaces lets your knowledge grow fast, because you get structured information. Ho

Re: [Zope3-dev] doctest: Get type of object

2006-01-24 Thread Florian Lindner
Am Dienstag, 24. Januar 2006 21:07 schrieb Florian Lindner: > Hello, > I'm currently writing a test in a README.txt and I want to make sure that > returned object a is of type zope.app.x. How can I test that? I've tried: Failed example: homeFolder #doctest: +ELLIPSIS Expected: Got nothin

[Zope3-dev] Deploying WSGI Apps with Zope 3.2+

2006-01-24 Thread Sidnei da Silva
Hello, I'm refactoring a application developed for Zope 3.0, and in the proccess of doing that, one of the things I wanted to do is to remove some hardcoded xslt pipeline and instead use a WSGI 'middleware' or 'filter'. So.. I was planning to use paste.deploy to put this together. However it seem

Re: [Zope3-dev] doctest: Get type of object

2006-01-24 Thread Tim Peters
[Florian Lindner] > I've tried: > > Failed example: > homeFolder #doctest: +ELLIPSIS > Expected: > > Got nothing > > > I've also tried it without the #doctest > > Why do I get just nothing? That's expected if (and only if) `homeFolder` is bound to `None`. What happens if you change t

Re: [Zope3-dev] Deploying WSGI Apps with Zope 3.2+

2006-01-24 Thread Jim Fulton
Sidnei da Silva wrote: Hello, I'm refactoring a application developed for Zope 3.0, and in the proccess of doing that, one of the things I wanted to do is to remove some hardcoded xslt pipeline and instead use a WSGI 'middleware' or 'filter'. Cool So.. I was planning to use paste.deploy to p

Re: [Zope3-dev] doctest: Get type of object

2006-01-24 Thread Florian Lindner
Am Dienstag, 24. Januar 2006 22:57 schrieb Tim Peters: > [Florian Lindner] > > > I've tried: > > > > Failed example: > > homeFolder #doctest: +ELLIPSIS > > Expected: > > > > Got nothing > > > > > > I've also tried it without the #doctest > > > > Why do I get just nothing? > > That's ex

[Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Florent Guillaume
Chris Withers wrote: Gary Poster wrote: FWIW, me too. I'm no XML guru (as Fred will attest ;-) ) but reading the namespaces on an XML file seems like basic XML procedure. Well, the reading of them is the lesser of my two complaints... I find it irksome to have to type them at the top of ev

[Zope3-dev] Re: RFC: ZConfig and other formats for ZCML

2006-01-24 Thread Florent Guillaume
Dieter Maurer wrote: What I like with "ZConfig" is its schemas and especially the ability to define datatypes. I hope that similar things can be achieved with ZCML. Of course it can, ZCML is defined in terms of Zope 3 schemas. Florent -- Florent Guillaume, Nuxeo (Paris, France) Director of

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Christian Lück
Shane Hathaway wrote: > Christian Lück wrote: > From a lerners point of view (for example me) the thematic organization >> >> is a pro too: The z3 beginner will probably need the 'zope' and >> 'browser' namespaces at first. Browsing apidoc zcml namespaces lets your >> knowledge grow fast, bec

Re: [Zope3-dev] Re: ZCML bad ;-)

2006-01-24 Thread Philipp von Weitershausen
Chris Withers wrote: > (and if we can get it down to one, we don't have to specify it at the > top of the file... yay!) Not really. Specifying no namespace at all is not the same as specifying the namespace of prefix-less elements. Even with one namespace the declaration of that namespace is still

[Zope3-dev] Re: Zope 3 Book

2006-01-24 Thread Mikhail Kashkin
Stephan, may be it is possible to publish your book again in Wiki format, and grant rights to other authors? Stephan Richter wrote: > On Monday 23 January 2006 10:22, Guido Hoffmeier wrote: >> I am new at Zope and at the moment I am struggling with the tutorial of >> the Zope 3 Book (Online Versio