Am 21.11.2005 um 12:15 schrieb Martijn Faassen:

My recommendations for any guidelines would be:

* use namespace packages, so nothing (or very minimal stuff only, like a few imports) in __init__.py. I think this is recommended practice outside of Zope 3 as well, so we should stick with this. Twisted seems to have small or empty __init__.py packages for instance, and so does PEAK, to compare with some other large frameworks in Python.

* use interfaces.py and put interfaces there unless there's a very good reason it should be private (which is rare).

I'm in support of all the suggestions Martijn has written. As a small addition I sometimes use a subdirectory interfaces with some modules, when I have many classes with different concerns in a namespace. But in the interfaces subdirectory I use __init__.py to import everything, so that for interface imports elsewhere it looks all the same.

with regards,

__Janko

_______________________________________________
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com

Reply via email to