]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/commitdiff
Refactoring to move the not_import_versionable and ignorable package lists to _auto_d...
authorDaira Hopwood <daira@jacaranda.org>
Thu, 25 Sep 2014 17:54:14 +0000 (18:54 +0100)
committerDaira Hopwood <daira@jacaranda.org>
Thu, 2 Oct 2014 00:34:00 +0000 (01:34 +0100)
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
src/allmydata/__init__.py
src/allmydata/_auto_deps.py

index 95019aaf54ec18e7e242c65550ffd1e3cee869e4..e7697e65fb7d16462a3121d264f22629e2db2e3e 100644 (file)
@@ -281,10 +281,10 @@ def cross_check_pkg_resources_versus_import():
 def cross_check(pkg_resources_vers_and_locs, imported_vers_and_locs_list):
     """This function returns a list of errors due to any failed cross-checks."""
 
+    from _auto_deps import not_import_versionable, ignorable
+
     errors = []
-    not_pkg_resourceable = set(['python', 'platform', __appname__.lower()])
-    not_import_versionable = set(['zope.interface', 'mock', 'pyasn1'])
-    ignorable = set(['argparse', 'pyutil', 'zbase32', 'distribute', 'twisted-web', 'twisted-core', 'twisted-conch'])
+    not_pkg_resourceable = ['python', 'platform', __appname__.lower()]
 
     for name, (imp_ver, imp_loc, imp_comment) in imported_vers_and_locs_list:
         name = name.lower()
index 2869a9e356df52f000c03b3ce8fc4ad9f54aae76..6365119ed204de7940786d32ad4d7eee2f82ddf5 100644 (file)
@@ -92,6 +92,24 @@ package_imports = [
     ('service-identity', 'service_identity')
 ]
 
+# Dependencies for which we don't know how to get a version number at run-time.
+not_import_versionable = [
+    'zope.interface',
+    'mock',
+    'pyasn1',
+]
+
+# Dependencies reported by pkg_resources that we can safely ignore.
+ignorable = [
+    'argparse',
+    'pyutil',
+    'zbase32',
+    'distribute',
+    'twisted-web',
+    'twisted-core',
+    'twisted-conch',
+]
+
 def require_more():
     import sys