Python web development, really

Afanasiy abelikov72 at hotmail.com
Mon Jan 20 18:16:52 CET 2003


I would love to use Python instead of PHP for web development, but
I have so far been confused by the options, or perhaps lack thereof,
given my strict requirements. I would appreciate suggestions.

I've looked at some Python options and have experience in quite a
few platforms previously. I have always disliked PHP as a language,
but at the same time have found it very accessible and useful.

Possible solutions should do 99% of the following :

* Run on the same hardware I use currently

* Be as fast or faster than Apache+PHP
  (I'm sorry to say Zope/Roxen are not)
  (This might mean it must use Apache)

* Use a similar amount of memory
  (ie. not Java/.NET related)

* Provide a fairly equivalent framework w/ sessions, cookies, get, post
  (Described in http://www.boddie.org.uk/python/web_frameworks.html)
  (eg. I should not have to write code to parse query strings, etc.)
  (PHP is somewhat unique in the ways it can bring in post variables)

* Allow all errors to be caught and handled so users never see them
  (I currently send them to an email address)
  (Users are notified an error occurred and a developer contacted)

* Allow sending of email

* Allow sending of raw binary data, for restricted file downloading
  (eg. http://example.com/sendfile.php?id=A6DE12FAB3...etc)
  (This requires header manipulation, specifically the mime type)
  (That sort of thing should be part of the framework 3 bullets up)

* Allow SSL secured authorize.net credit card processing
  (I currently use PHP's libcurl+ssl module)
  
* Allow similarly powerful regex capabilities
  (I currently use PHP's pcre module)

* Big plus, but optional, auto prepend/append files
  (eg. Apache+PHP has .htaccess directives like this )
  (    php_value auto_prepend_file "_header.php"     )
  (    php_value auto_append_file "_footer.php"      )
  (granular down to the directory 

* Finally, very optional plus, global application scoped variables
  (PHP does NOT allow this, but I know why)
  (I do not want to hear why you think this is bad)
  (I know why it is good, I know why it can be bad)

Some of these things likely already exist in Python itself and thus
in anything which uses Python in a web development solution, but I am
mentioning them explicitly because they are indeed still requirements.
Plus explicit is better than implicit, as I'm sure everyone knows. ;-)

Some links for future and others' reference :
  http://www.boddie.org.uk/python/web_frameworks.html
  http://www.boddie.org.uk/python/web_modules.html
  http://webware.sf.net/
  http://modsnake.sf.net/ (dead? that's too bad)
  http://www.apache.org/dist/httpd/modpython/
  http://pmz.sourceforge.net/
  http://www.mems-exchange.org/software/quixote/
  http://skunkweb.sourceforge.net/

I hope I have not forgotten anything which will lead this thread to hell.





More information about the Python-list mailing list