diff options
-rw-r--r-- | baserockimport/mainloop.py | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/baserockimport/mainloop.py b/baserockimport/mainloop.py index f17865f..483e8b2 100644 --- a/baserockimport/mainloop.py +++ b/baserockimport/mainloop.py @@ -283,20 +283,22 @@ class ImportLoop(object): def _update_queue_and_graph_with_dependency(self, current_item, kind, name, version, is_build_dep, to_process, processed, errors): - failed_dep_package = find( - errors, lambda i: i.match(kind, name, version)) + failed_dep_package = find(errors, + lambda pkg: pkg.match(kind, name, version)) + if failed_dep_package: logging.debug( "Ignoring %s as it failed earlier.", failed_dep_package) return - dep_package = find( - processed, lambda i: i.match(kind, name, version)) + dep_package = find(processed, + lambda pkg: pkg.match(kind, name, version)) if dep_package is None: # Not yet processed - queue_item = find( - to_process, lambda i: i.match(kind, name, version)) + queue_item = find(to_process, + lambda pkg: pkg.match(kind, name, version)) + if queue_item is None: queue_item = baserockimport.package.Package( kind, name, version) |