24
24
# packages listed in the Sources file we imported, but also packages
25
25
# that have been recently deleted.
26
26
package_counts = dominator.findPublishedSourcePackageNames(series, pocket)
27
for package_name, package_count in package_counts:
27
for package_name, pub_count in package_counts:
28
28
entries = packages_map.src_map.get(package_name, [])
30
30
entry['Version'] for entry in entries if 'Version' in entry]
32
dominator.dominateRemovedSourceVersions(
33
series, pocket, package_name, live_versions)
32
# Gina import just ensured that any live version in the Sources
33
# file has a Published publication. So there should be at least
34
# as many Published publications as live versions.
35
if pub_count < len(live_versions):
37
"Package %s has fewer live source publications (%s) than "
38
"live versions (%s). The archive may be broken in some "
40
package_name, pub_count, len(live_versions))
42
# Domination can only turn Published publications into
43
# non-Published ones, and ensures that we end up with one
44
# Published publication per live version. Thus, if there are as
45
# many Published publications as live versions, there is no
46
# domination to do. We skip these as an optimization. Without
47
# it, dominating a single Debian series takes hours.
48
if pub_count != len(live_versions):
49
dominator.dominateRemovedSourceVersions(
50
series, pocket, package_name, live_versions)