Re: Modules & positive surprises

2007-03-30 Thread Steven Bethard
Jan Danielsson wrote:
>But then there are a few modules that I just love to use, because
> they are so "clean" from interface to function. Among them I can't help
> mentioning optparse.


If you like optparse, you should try argparse:

 http://argparse.python-hosting.com/

It has an optparse-style API, along with support for

* positional arguments
* sub-commands
* required options
* options with a variable number of args
* better usage messages
* a much simpler extension mechanism

and more...



STeVe
-- 
http://mail.python.org/mailman/listinfo/python-list


Re: Modules & positive surprises

2007-03-27 Thread kyosohma
On Mar 27, 8:30 am, Jan Danielsson <[EMAIL PROTECTED]> wrote:
> Hello all,
>
> 
>
>Although I have encountered many modules that have impressed me with
> regards to what they can actually do -- too be perfectly honest, it's
> very rare that I become impressed by the _interfaces_ to the modules.
>
>Using a new module is normally, with my - admittedly - limited
> experience, a pain. It's not just about reading the reference material,
> and then just use it. You have to figure out how the developer who wrote
> the module was thinking. Often there's a (more or less) natural way to
> do things, and unfortunately that's not how module developers do it.
> It's not a major issue to me personally, since the important part is
> that the module can perform its function.
>
>But then there are a few modules that I just love to use, because
> they are so "clean" from interface to function. Among them I can't help
> mentioning optparse.
>
>Yesterday I found another module which I fell in love with: Python
> Cryptography Toolkit (http://www.amk.ca/python/writing/pycrypt/).
>
>It's just so ... elegant, and functional.
>
> 
>
> --
> Kind regards,
> Jan Danielsson

Yeah. I've noticed that myself. There are tons of good modules, but a
lot of the docs are lousy. What's really annoying is that everyone
says that so-and-so is well documented. I love Python, but I wish when
they said some module was well documented, they meant that the docs
were understandable (to n00bs) as well.

Mike

-- 
http://mail.python.org/mailman/listinfo/python-list


Modules & positive surprises

2007-03-27 Thread Jan Danielsson
Hello all,



   Although I have encountered many modules that have impressed me with
regards to what they can actually do -- too be perfectly honest, it's
very rare that I become impressed by the _interfaces_ to the modules.

   Using a new module is normally, with my - admittedly - limited
experience, a pain. It's not just about reading the reference material,
and then just use it. You have to figure out how the developer who wrote
the module was thinking. Often there's a (more or less) natural way to
do things, and unfortunately that's not how module developers do it.
It's not a major issue to me personally, since the important part is
that the module can perform its function.

   But then there are a few modules that I just love to use, because
they are so "clean" from interface to function. Among them I can't help
mentioning optparse.

   Yesterday I found another module which I fell in love with: Python
Cryptography Toolkit (http://www.amk.ca/python/writing/pycrypt/).

   It's just so ... elegant, and functional.



-- 
Kind regards,
Jan Danielsson
-- 
http://mail.python.org/mailman/listinfo/python-list