diff options
author | dlehman <dlehman> | 2007-01-16 19:31:40 +0000 |
---|---|---|
committer | dlehman <dlehman> | 2007-01-16 19:31:40 +0000 |
commit | 3e1cb15b411ba0fd11bff575bd9f5fe2675f3f3c (patch) | |
tree | 4e9e861730dbc1e2efe6095ad1ddec89849983cd | |
parent | 6ad1068b31dcbacf108345db286063c1e1314527 (diff) | |
download | anaconda-3e1cb15b411ba0fd11bff575bd9f5fe2675f3f3c.tar.gz anaconda-3e1cb15b411ba0fd11bff575bd9f5fe2675f3f3c.tar.xz anaconda-3e1cb15b411ba0fd11bff575bd9f5fe2675f3f3c.zip |
* yuminstall.py (doPostSelection): remove packages added to solve
dependencies if we can't accept the package selection because of
limited disk space (#222894)
* yuminstall.py (_undoDepInstalls): new method to remove transaction
members that are only there because something depends on them
-rw-r--r-- | ChangeLog | 9 | ||||
-rw-r--r-- | yuminstall.py | 9 |
2 files changed, 17 insertions, 1 deletions
@@ -1,3 +1,12 @@ +2007-01-16 Dave Lehman <dlehman@redhat.com> + + * yuminstall.py (doPostSelection): remove packages added to solve + dependencies if we can't accept the package selection because of + limited disk space (#222894) + + * yuminstall.py (_undoDepInstalls): new method to remove transaction + members that are only there because something depends on them + 2007-01-16 Peter Jones <pjones@redhat.com> * yuminstall.py (YumSorter.__init__): make yum use anaconda's loggers. diff --git a/yuminstall.py b/yuminstall.py index 315656294..9b93d96ee 100644 --- a/yuminstall.py +++ b/yuminstall.py @@ -380,6 +380,12 @@ class YumSorter(yum.YumBase): return best return None + def _undoDepInstalls(self): + # clean up after ourselves in the case of failures + for txmbr in self.tsInfo: + if txmbr.isDep: + self.tsInfo.remove(txmbr.pkgtup) + def prof_resolveDeps(self): fn = "anaconda.prof.0" import hotshot, hotshot.stats @@ -455,7 +461,7 @@ class YumSorter(yum.YumBase): found = True break if not found: - txmbr.setAsDep(member.po) + member.setAsDep(txmbr.po) return unresolved @@ -1157,6 +1163,7 @@ class YumBackend(AnacondaBackend): if rc == 1: sys.exit(1) else: + self.ayum._undoDepInstalls() return DISPATCH_BACK finally: dscb.pop() |