summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeremy Katz <katzj@redhat.com>2002-12-31 07:21:17 +0000
committerJeremy Katz <katzj@redhat.com>2002-12-31 07:21:17 +0000
commit9922d97eb50eb30eedb8ef0fc00b540c8dcf41f3 (patch)
treea44d21b2337b443099211a2abc788f5e324754e6
parent41941be87707824d8562ae7f91c351da1ac8a5cd (diff)
downloadanaconda-9922d97eb50eb30eedb8ef0fc00b540c8dcf41f3.tar.gz
anaconda-9922d97eb50eb30eedb8ef0fc00b540c8dcf41f3.tar.xz
anaconda-9922d97eb50eb30eedb8ef0fc00b540c8dcf41f3.zip
this fixes the weird behavior where unselecting a package wouldn't unselect it.
between looking at cvs logs and doing some testing with it, the condition that this was originally working around looks to be fixed (if you had an optional package somewhere that was mandatory somewhere else the state would get screwed up). the UI is still slightly non-intuitive since we don't tell you that it's still going to be installed (aside from a log message), but if we pop them up for everything, then we end up like dselect which isn't right either.
-rw-r--r--comps.py7
1 files changed, 2 insertions, 5 deletions
diff --git a/comps.py b/comps.py
index e473ed0f6..a9ed09aaf 100644
--- a/comps.py
+++ b/comps.py
@@ -377,11 +377,6 @@ class Component:
if p not in self.newpkgDict.keys():
log("%s not in pkgDict for component %s" % (p.name, self.name))
else:
- # dont ref count more than once
- if p in self.pkgDict.keys():
- log("%s already enabled in pkgDict for component %s" % (p.name, self.name))
- return
-
self.newpkgDict[p] = (PKGTYPE_OPTIONAL, 1)
p.registerComponent(self)
self.pkgDict[p] = None
@@ -415,6 +410,8 @@ class Component:
self.depsDict[p.name] = self.depsDict[p.name] - 1
if self.depsDict[p.name] == 0:
del self.depsDict[p.name]
+ else:
+ log("%s is required elsewhere (either as a dependency or for a group), remaining installed to satisfy" %(p.name,))
self.updateDependencyCountForRemoval(p)
elif isinstance(p, Component):
p.unselect(forInclude = 1, toplevel = 0)