PSP, Cheetah, PTL, ZOPE, etc ...

Graham Dumpleton grahamd at dscpl.com.au
Wed Aug 1 13:15:34 CEST 2001


Go to:

  http://webware.sourceforge.net/Papers/Templates/

and one will find a growing list of packages designed to provide a means
of generating HTML pages using Python in one way or another. These range
from % on steroids (ie. Cheetah), up to ASP or JSP workalikes (ie. PSP).
Although not specifically Python, you also have the traditional server
side includes feature of Apache, that might easily be beefed up somewhat
to make it more useable within the confines of an appropriate HTTP servlet
framework implemented using Python.

With the more complicated of these, eg., PSP or Zope, I think I can safely
say they got to where they are through gradual evolvement. With such an
approach, what can happen though is that one can introduce a way of doing
things which may turn out not to be the best way. The result of this is
that in time another way is introduced of doing the same thing but perhaps
a bit better. Because someone might be using the initial feature though, it
gets left in there, resulting in a not so clean and consistant implementation
or set of features. In other words, it develops warts.

What I am wanting to know is what we have learnt from all of this. If
one were designing yet another template system, what might be the best way
of approaching it? The idea being for it to be simple in appearance and
use, yet be powerful enough to harness features within the back end server.

Given the popularity of ASP and JSP, starting with the concept of PSP as
one mechanism is appealing. In looking at PSP however, I see the different
ways which exist of handling the indentation problem as being confusing. I
would prefer to see just one way of doing it. There are also possibly other
things that might sensibly be dropped from a new implementation of PSP.

As well as PSP, you also have other approaches such as Zope, which on
first inspection may be quite daunting to many users. Zope also perhaps
pushes the functionality more into the server than the web pages as with
PSP, which might mean more work before one can get something going.

Is there are middle ground? Based on experiences from using these systems,
are we at a point where we can say that something better now might be
developed, or do people think this is the best we can do?

BTW, when I say PSP here, I am refering to the WebWare implementation.
As to why I am asking these questions, well, I have a HTTP servlet and
distributed application framework with publish/subscribe and request/reply
functionality. The issue now is how to make it all easily accessible so
that building web services can be made simple.

Any comments, ideas or suggestions are most welcome.



More information about the Python-list mailing list