mirror of
https://git.launchpad.net/ubuntu-dev-tools
synced 2025-05-13 01:41:29 +00:00
Use a seeded defaultdict for the intermediate data structure, in case of binary package name differences between releases
This commit is contained in:
parent
d125c47081
commit
222ab46cff
@ -14,7 +14,7 @@
|
|||||||
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
|
||||||
import collections
|
from collections import defaultdict
|
||||||
import optparse
|
import optparse
|
||||||
import sys
|
import sys
|
||||||
|
|
||||||
@ -116,8 +116,12 @@ def find_rdepends(package, releases):
|
|||||||
for bpph in package._lpobject.getPublishedBinaries():
|
for bpph in package._lpobject.getPublishedBinaries():
|
||||||
published_binaries.add(bpph.binary_package_name)
|
published_binaries.add(bpph.binary_package_name)
|
||||||
|
|
||||||
intermediate = dict((binpkg, collections.defaultdict(list))
|
intermediate = defaultdict(lambda: defaultdict(list))
|
||||||
for binpkg in published_binaries)
|
|
||||||
|
# We want to display every pubilshed binary, even if it has no rdepends
|
||||||
|
for binpkg in published_binaries:
|
||||||
|
intermediate[binpkg]
|
||||||
|
|
||||||
for arch in ('any', 'source'):
|
for arch in ('any', 'source'):
|
||||||
for release in releases:
|
for release in releases:
|
||||||
try:
|
try:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user