From: Zooko O'Whielacronx Date: Wed, 30 Apr 2008 20:22:04 +0000 (-0700) Subject: setup: don't catch ImportError when importing _auto_deps in allmydata/__init__.py X-Git-Tag: allmydata-tahoe-1.1.0~171 X-Git-Url: https://git.rkrishnan.org/Site/Content/Exhibitors/nxhtml.html?a=commitdiff_plain;h=fc271a0ee9b31a8dfcf0207e7f4ebfa7ef99f2cd;p=tahoe-lafs%2Ftahoe-lafs.git setup: don't catch ImportError when importing _auto_deps in allmydata/__init__.py Nowadays pkg_resources is a runtime requirement, and if there is something screwed up in the installation, we want an explicit ImportError exception as early as possible. --- diff --git a/src/allmydata/__init__.py b/src/allmydata/__init__.py index d67ec9b0..f79b93ff 100644 --- a/src/allmydata/__init__.py +++ b/src/allmydata/__init__.py @@ -19,16 +19,8 @@ except ImportError: hush_pyflakes = __version__ del hush_pyflakes -try: - import _auto_deps -except ImportError: - # Never mind -- even if we can't use pkg_resources to check the required - # version numbers and to select the right one in the case that more than one - # version is available, we can still barrel on and if "import thingie" gives - # us a thingie that works, we're okay. - pass -else: - _auto_deps.require_auto_deps() +import _auto_deps +_auto_deps.require_auto_deps() def get_package_versions(): import OpenSSL, allmydata, foolscap, nevow, pycryptopp, simplejson, twisted, zfec