On Dec 20, 2010, at 4:22 AM, Hong MinHee wrote: > Hi everyone, > > I’ve been written a small extension that introduces promise/future[1] > model to SQLAlchemy query objects. The documentation can be found > http://lunant.github.com/SQLAlchemy-Future/ but it’s written in my > awkward English, so any indications about my writing are welcome. > > Anyway, there is a trivial problem. I wanted to make its module name > `sqlalchemy.ext.future` or `sqlalchemy.contrib.future`, but it > requires the declaration that `sqlalchemy.ext` or `sqlalchemy.contrib` > are namespace packages. So I named the module as just `future` > unwillingly currently. > > In short, it is my question: What module name is good for this > package? Or, could a slightly standardized namespace like > `sqlalchemy.ext`/`sqlalchemy.contrib` defined by Michael Bayer? > > [1] http://en.wikipedia.org/wiki/Futures_and_promises
OK, reading http://www.python.org/dev/peps/pep-0382/ http://stackoverflow.com/questions/1675734/how-do-i-create-a-namespace-package-in-python http://peak.telecommunity.com/DevCenter/setuptools#namespace-packages , it seems like the current system for this would be: diff -r 0e489ba1b1be lib/sqlalchemy/contrib/__init__.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/lib/sqlalchemy/contrib/__init__.py Mon Dec 20 11:10:26 2010 -0500 @@ -0,0 +1,2 @@ +from pkgutil import extend_path +__path__ = extend_path(__path__, __name__) What's not clear to me is why setuptools provides a different function, or if the setuptools function is required for packages that are installed via setuptools, or if the setuptools/pkgutil functions are mutually exclusive. -- You received this message because you are subscribed to the Google Groups "sqlalchemy" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/sqlalchemy?hl=en.
