[Tutor] Tutor Digest, Vol 61, Issue 3

Daniele d.conca at gmail.com
Sun Mar 1 22:44:01 CET 2009


> From: W W <srilyk at gmail.com>
> Subject: Re: [Tutor] modular program

>>Where can I find some "best practices" for writing modular programs?
>> I thought about a txt file containing function calls that my program will
>> parse and execute in order, or is it better just to execute every .py file
>> in a certain "module" folder (I don't like this as modules could need to be
>> executed in different moments)?

> You can pretty much take a look at any of the modules in your python
> library directory. In the case of my linux box, that's
> /usr/lib/python2.5/

I'm sorry, I've realized I didn't explain my needs at all.
I was a little influenced by drupal's definition of modules, which is
completely different from python's.
With module here I meant plug-in or extension: a piece of code written
by someone else that can be easily (and automaticallly) integrated
into my program.
My program must provide the posibility to be extended without editing
its code, just like mozilla's add-ons.


More information about the Tutor mailing list