From 876e61a7692b121c2a1ac68a8cb0739101c213c4 Mon Sep 17 00:00:00 2001 From: Ansgar Burchardt Date: Fri, 20 Jul 2012 13:10:54 +0200 Subject: [PATCH] daklib/archive.py: guess source component even with component mappings --- daklib/archive.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/daklib/archive.py b/daklib/archive.py index 914bc0f3..539a8d20 100644 --- a/daklib/archive.py +++ b/daklib/archive.py @@ -1101,7 +1101,8 @@ class ArchiveUpload(object): component = binary_component_func(binary) binary_component_names.add(component.component_name) source_component_name = None - for guess in ('main', 'contrib', 'non-free'): + for c in self.session.query(Component).order_by(Component.component_id): + guess = c.component_name if guess in binary_component_names: source_component_name = guess break -- 2.39.5