From 8446ea8b7785892eeb4ad83ee1d0f07e0e5d4f38 Mon Sep 17 00:00:00 2001 From: Luca Giovenzana Date: Tue, 16 May 2017 14:21:43 +0200 Subject: [PATCH] Fix https://github.com/smartpm/smart/issues/11 the case when origchangeset.get(pkg) returns None patch by Peter Warasin peter@endian.com https://bugs.launchpad.net/smart/+bug/1181251 --- smart/transaction.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/smart/transaction.py b/smart/transaction.py index 4b90cb7..bb65b7a 100644 --- a/smart/transaction.py +++ b/smart/transaction.py @@ -1028,7 +1028,8 @@ def _upgrade(self, pkgs, changeset, locked, pending, depth=0): for pkg in changeset.keys(): op = changeset.get(pkg) - if (op and op != origchangeset.get(pkg) and + origpkgop = origchangeset.get(pkg) + if (op and origpkgop != None and op != origpkgop and pkg not in locked and pkg not in lockedstates): try: