From 6fc3e09fbd4c5d72b40450529d30fbd8fbba9300 Mon Sep 17 00:00:00 2001 From: Pavan Rikhi Date: Mon, 14 Nov 2016 12:17:56 -0500 Subject: [PATCH] Fix find_newer_versions for Removed Packages Finding a newer version of a package fails when that package has been removed or renamed. This patch fixes this by skipping any removed/renamed packages when attempting to find newer versions. --- elm_deps_upgrade.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/elm_deps_upgrade.py b/elm_deps_upgrade.py index da97443..f84d23b 100755 --- a/elm_deps_upgrade.py +++ b/elm_deps_upgrade.py @@ -92,6 +92,8 @@ def find_newer_versions(local_deps, remote_deps): upgrade_suggestions = {} for (dep, version) in local_deps.items(): + if dep not in remote_deps: + continue current_version = top_range(version) patches = get_patch_upgrades(current_version, remote_deps[dep]['versions']) minors = get_minor_upgrades(current_version, remote_deps[dep]['versions'])