From: david-sarah Date: Sun, 31 Oct 2010 17:46:49 +0000 (-0700) Subject: allmydata/__init__.py: put the _auto_deps.require_auto_deps() call back in exactly... X-Git-Tag: trac-4800~5 X-Git-Url: https://git.rkrishnan.org/%5B/frontends/%22file:/flags/?a=commitdiff_plain;h=63c010a9ca4e6379b044deccc3da6096782fc1b6;p=tahoe-lafs%2Ftahoe-lafs.git allmydata/__init__.py: put the _auto_deps.require_auto_deps() call back in exactly the same place it was prior to [4784]. --- diff --git a/src/allmydata/__init__.py b/src/allmydata/__init__.py index 96ee8563..03b86cf1 100644 --- a/src/allmydata/__init__.py +++ b/src/allmydata/__init__.py @@ -45,19 +45,6 @@ warnings.filterwarnings("ignore", category=DeprecationWarning, message="BaseException.message has been deprecated as of Python 2.6", append=True) -# Ideally we would call require_auto_deps() before importing nevow and twisted, but -# that causes midnightmagic's NetBSD buildslave to be unable to import allmydata.test, -# for reasons that are not understood. We want to call require_auto_deps() before other -# imports because the setuptools docs claim that if a distribution is installed with -# --multi-version, it might not importable until after pkg_resources.require() -# has been called for it. We don't have an example of this happening at this time. -# It is possible that require() isn't actually needed because we set __requires__ -# in the generated startup script, but that would be an undocumented property of the -# setuptools implementation. - -from allmydata import _auto_deps -_auto_deps.require_auto_deps() - __version__ = "unknown" try: from allmydata._version import __version__ @@ -79,6 +66,19 @@ except ImportError: # http://allmydata.org/trac/tahoe/wiki/Versioning __full_version__ = __appname__ + '/' + str(__version__) +# Ideally we would call require_auto_deps() before importing nevow and twisted, but +# that causes midnightmagic's NetBSD buildslave to be unable to import allmydata.test, +# for reasons that are not understood. We want to call require_auto_deps() before other +# imports because the setuptools docs claim that if a distribution is installed with +# --multi-version, it might not importable until after pkg_resources.require() +# has been called for it. We don't have an example of this happening at this time. +# It is possible that require() isn't actually needed because we set __requires__ +# in the generated startup script, but that would be an undocumented property of the +# setuptools implementation. + +from allmydata import _auto_deps +_auto_deps.require_auto_deps() + import os, platform, re, subprocess, sys _distributor_id_cmdline_re = re.compile("(?:Distributor ID:)\s*(.*)", re.I) _release_cmdline_re = re.compile("(?:Release:)\s*(.*)", re.I)