Just a thought...
why not keep the XML config, but use a preprocessed form?
for example:
<puffin>
� �<!-- System configuration settings. -->
� �<system>
� � � <server host="localhost" port="80"/>
� � � <frameworkLogging channelPriority="WARN">
� � � � �<handler type="StreamHandler">
� � � � � � <param name="msgFormat"><![CDATA[%(message)s]]></param>
� � � � �</handler>
</frameworkLogging>
</system>
</puffin>
could be written as:
------------------------------------------------------------------------------------------------------
puffin
system
server(host="localhost" port ="80")
frameworkLogging(channelPriority="WARN")
handler(type="StreamHandler")
param(name="msgFormat") <![CDATA[%(message)s]]>
-------------------------------------------------------------------------------------------------------
(I left out huge parts of the config :-)
This might have the right balance between xml config file and a pythonic
feeling.
Last year, I posted some code, that should work with the above example here
on this list:
http://www.geocrawler.com/archives/3/3854/2001/6/100/5988545/
You can find something very similar (XML preprocessing in python) at
http://www.scottsweeney.com/projects/slip
Scotts code is more mature and better maintained than mine (shame on me)
If you have any question about this, I'm on holiday for two weeks, so please
drop a private mail.
-stephan
> Date: Thu, 6 Jun 2002 20:27:16 -0700
>
> On Thursday 06 June 2002 06:38 pm, A. Keyton Weissinger wrote:
> > As some of you know, I *LOVE* python. But I gave up trying to force
> > others to love it.
> >
> > There are some hardcore Perl geeks out there that like Puffin but
> > hate Python. I have even more requests for a Perl-based
>
> scripting
>
> > interface than I do a Python-based one.
>
> Okay, I have other points below, but the first one is:
>
> o Screw people who hate Python.
>
> > Now what you suggest about making the underlying data structure
> > Python does make a lot of sense. I will continue to look and
> > experiment with that. However, I'm guessing that if I do that, then
> > until I get a GUI for the non-Python folks, the only people that will
> > help Puffin evolve are the Pythonistas.
> >
> > Now don't get me wrong, these are clearly the "chosen people" and
> > Puffin could do a lot worse with theirs being the governing voices.
> > But there are not all that many of them. If I leave it open (i.e.
> > predominantly XML-based) then I get LOTS more eyes on the thing and
> > make it better for EVERYONE.
>
> I'm not clear on this. Isn't Puffin already in Python? The architecure
> I laid out did NOT remove the XML layer. It just opened up the innards
> as something that an enlightened (aka Pythonic) person could use in the
> native language. The XML folks would still use the Puffin XML
> interface. And some declarative, but anti-XML folks could use a Python
> dict instead of an XML doc.
>
> So I don't see how you think things would get closed.
>
> - Python folks subclass Plan.
> - XML folks invoke the puffin XMLPlan util/class from the command line.
>
>
> It's like Python let's *me* decide if I want to write platform specific
> code, or independant code.
> And I like having that choice.
>
> Puffin should let me decide if I want to be a Python QA scripter or an
> XML QA scripter.
>
> > As for using WebUnit. I certainly do NOT have anything against it. It
> > makes a lot of sense. I didn't use it the first time around because I
>
> I've used it and I'm happy with it overall. At the time, some of the
> terminology was a bit strange coming from the HTTP spec and OO. An
> httpsession is really a "user agent". Or at least that's the term that
> most precisely matches it.
>
> I usually deem "sessions" as the actual session objects found on the
> server side in the app server, or the "gray" concept of a user sitting
> at a web site for awhile which could arguably include or NOT include a
> URL history, a log of pages, mouse clicks, etc.
>
> This extended into other areas concerning request and response objects
> and other tidbits. But I haven't updated in several months, so I'm not
> sure of the current state.
>
> But nothing stopped me from getting my test script written, so thanks
> Steve!
>
>
> -Chuck
>
> _______________________________________________________________
>
> Don't miss the 2002 Sprint PCS Application Developer's Conference
> August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm
>
> _______________________________________________
> Webware-discuss mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/webware-dis
> cuss
_______________________________________________________________
Don't miss the 2002 Sprint PCS Application Developer's Conference
August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm
_______________________________________________
Webware-discuss mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/webware-discuss