Ensure files mentioned in Packages & Sources exist
"""
for suite in [ "stable", "testing", "unstable" ]:
- for component in Cnf.ValueList("Suite::%s::Components" % (suite)):
+ for component in get_component_names():
architectures = get_suite_architectures(suite)
for arch in [ i.arch_string.lower() for i in architectures ]:
if arch == "source":
# Parse the Packages files (since it's a sub-second operation on auric)
suite = "stable"
stable = {}
- components = cnf.ValueList("Suite::%s::Components" % (suite))
+ components = get_component_names()
architectures = [ a.arch_string for a in get_suite_architectures(suite, skipsrc=True, skipall=True) ]
for component in components:
for architecture in architectures:
bins_in_suite = get_suite_binaries(suite, session)
# Checks based on the Sources files
- components = cnf.ValueList("Suite::%s::Components" % (suite_name))
+ components = get_component_names(session)
for component in components:
filename = "%s/dists/%s/%s/source/Sources.gz" % (cnf["Dir::Root"], suite_name, component)
# apt_pkg.ParseTagFile needs a real file handle and can't handle a GzipFile instance...
depends = set()
rdepends = set()
- components = cnf.ValueList("Suite::%s::Components" % suite)
+ components = get_component_names(session)
arches = set([x.arch_string for x in get_suite_architectures(suite)])
arches -= set(["source", "all"])
for arch in arches:
depends = {}
session = DBConn().session()
suite = Options['suite']
- components = cnf.ValueList('Suite::%s::Components' % suite)
+ components = get_component_names(session)
arches = set([x.arch_string for x in get_suite_architectures(suite)])
arches -= set(['source', 'all'])
for arch in arches:
cnf = Config()
print "Checking reverse dependencies..."
- components = cnf.ValueList("Suite::%s::Components" % suites[0])
+ components = get_component_names()
dep_problem = 0
p2c = {}
all_broken = {}
entry["component"] = dest
# Ensure the component is valid for the target suite
- if cnf.has_key("Suite:%s::Components" % (suite)) and \
- entry["component"] not in cnf.ValueList("Suite::%s::Components" % (suite)):
+ if entry["component"] not in get_component_names(session):
self.rejects.append("unknown component `%s' for suite `%s'." % (entry["component"], suite))
return