[Python-Dev] On breaking modules into packages Was: [issue10199] Move Demo/turtle under Lib/

Guido van Rossum guido at python.org
Tue Nov 2 23:58:51 CET 2010


On Tue, Nov 2, 2010 at 3:47 PM, Raymond Hettinger
<raymond.hettinger at gmail.com> wrote:
> I'm not sure I follow where we're stuck with the current package.
> AFAICT, the module is still used with "import unittest".
> The file splitting was done badly, so I don't think there any of the
> components are usable directly, i.e. "from unitest.case import SkipTest".
> Also, I don't think the package structure was documented or announced.
>
> This is in contrast to the logging module which does have a
> clean separation of components and where it isn't unusual
> to import just part of the package.
>
> What is it you're seeing as a risk that I'm not seeing?
> Are we permanently locked into the exact ten filenames
> that are currently used:  utils, suite, loader, case, result, main, signals,
> etc?
> Is the file structure now frozen?

To spout a somewhat contrarian opinion, I just browsed the new
unittest package, and the structure seems reasonable to me, even if
its submodules are not particularly reusable. I've used this kind of
style for development myself. What is so offensive about it?

-- 
--Guido van Rossum (python.org/~guido)


More information about the Python-Dev mailing list