bad python modules

Vetle Roeim vr at acm.org
Mon Nov 13 15:32:55 EST 2000


* sp00fD at yahoo.com
> As a language, I like python more than perl.  However, the modules that
> are available seem lacking in comparison to perl's.  Why is this?  Is
> it just because python is not as popular as perl?  I can't think that
> that has much to do with it, because my gripe here is not the lack of
> modules, but the quality of the available modules.  A lot of what I'm
> talking about is somewhat silly, for instance:
> 
> In perl, the CGI module to be specific, you have cookie capability
> built in.  Why not with the python cgi module?  Why must I get a
> seperate (non-standard, not as good) module to handle cookies?  

well.. let's turn the question upside down. why not?

although often used together, CGI and Cookies are two different
things. Cookies have their own HTTP header, while CGI uses either the
URL (using the GET method) or sends the information as data (using the
POST method).

two separate things that are implemented in two separate modules.


> Why must I do a:
> 
> print "Content-type: text/html"
> 
> rather than
> 
> print cgi.header() # or something?

generation of HTML doesn't really have anything to do with CGI, and
IMHO it shouldn't be in a CGI-module. there are separate modules for
generating HTML, and you are free to use those.

the general philosophy used in Python modules seems to be that a
module should try to do one single thing.

 
[snip]


vr



More information about the Python-list mailing list