Python web development, really
abelikov72 at hotmail.com
Tue Jan 21 05:15:02 CET 2003
On Mon, 20 Jan 2003 21:50:43 +0100, Max M <maxm at mxm.dk> wrote:
>> * 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)
>So you want the advantages of Python, but none of the trade-off's. Well
>wouldn't we all?
I was not aware Python required trade-offs involving memory or cpu use in
order to compete with PHP. In my experience Python is much much faster for
basic scripting. I hoped that speed could be put to use on a web platform.
>> * 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)
>try/except works like a charm for this. Use it myself.
That works, yes. A wider scope error handler is preferred, but this
this can be irrelevant if an auto prepend/append file is allowed.
>> * 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)
>It is not quite clear what you mean here. But if you want to send a file
>from your server to another webserver/form, you just use urllib/urllib2.
>If you want to receive files on your server it is built into the cgi module.
To clarify, this requirement means I need to be able to completely replace
the request result such that it is in effect returning a binary file for
download. This is often used for secure downloading of protected files.
This requirement implies some method for customizing request result
headers, specifically Content-type/disposition/transfer-encoding/etc.
A good platform will simply allow customization of all headers.
(Header modification, as mentioned, is part of the framework requirement)
Additionally, some platforms might have a problem with including the
binary file as the actual result of the request (after the headers).
>> * Allow SSL secured authorize.net credit card processing
>> (I currently use PHP's libcurl+ssl module)
>Doesn't Apache do this?
No, this requirement is not about running an SSL HTTP server. This
requirement is about *programmatically* sending data to a secured remote
server via POST and receiving a response. This is how authorize.net works.
This requirement does imply an SSL capable HTTP server in order to
securely obtain said data from the user (only if you do that though).
All of these requirements imply an HTTP server as well... :p
> [plenty of things snipped]
I am looking for suggestions on a platform which might provide all of
these things. A platform, using Python, which can compete well with PHP.
More information about the Python-list