Python Namespace Problem

Tue 13 December 2005

This problem periodically comes up, and generally an unsatisfactory solution is proposed, the cure is worse than the disease, it's rejected, and we ignore the problem for another year.

The 1:1 correspondence of modules to files in Python is handy, but sometimes inconvenient. I would like to be able to write large, complex packages in Python but constrain the interface that they present, so that users only have to import one module in order to use them.

What is a good way to do this?
© Glyph 2015; All Rights Reserved Excepting Those Which Are Not.