Breaking up the importer's huge icommon.py file
Andrew Bennetts
andrew.bennetts at canonical.com
Mon May 23 06:42:01 UTC 2011
Max Bowsher wrote:
> A huge amount of the UDD importer's interesting code is in one file,
> icommon.py.
>
> I'd like to submit a series of changes to break it up such that only the
> most common bits of code remain there.
This all sounds pretty reasonable to me.
However I don't much care for the “ifoo” module naming convention. I
assume the “i” stands for “importer” but it always makes me think
“interface” first.
If we want a namespace for these modules (and I think we do; namespaces
are a good idea[1]) then let's do that the standard Python way: with a
package. Because I'm uncreative with names I suggest calling it
“package_importer”, or perhaps “udd”. So rather than “idatabase” I
propose “package_importer.database”. What do you think?
This would have the advantage of keeping the directory of scripts that
are interesting for a person to run mostly separate from the libraries
used to implement them. At the moment they're jumbled together.
-Andrew.
[1] Actually, not just good, honking great: python -c 'import this'
More information about the ubuntu-distributed-devel
mailing list