summaryrefslogtreecommitdiffstats
path: root/pyanaconda/packaging
diff options
context:
space:
mode:
authorChris Lumens <clumens@redhat.com>2012-10-08 14:36:31 -0400
committerChris Lumens <clumens@redhat.com>2012-10-09 10:12:17 -0400
commit8dfe97833f67559e9f070145d752355220e29045 (patch)
tree0682fe8653f6a368a32c52a2cc5f4dd145a4edcf /pyanaconda/packaging
parent2b541e520c2abc43e29f0a7743de015bce4d7514 (diff)
downloadanaconda-8dfe97833f67559e9f070145d752355220e29045.tar.gz
anaconda-8dfe97833f67559e9f070145d752355220e29045.tar.xz
anaconda-8dfe97833f67559e9f070145d752355220e29045.zip
When changing environments, don't explicitly exclude groups (#863886).
Otherwise, you'll end up in a situation where packages the previous and current environment share will not get installed.
Diffstat (limited to 'pyanaconda/packaging')
-rw-r--r--pyanaconda/packaging/__init__.py3
-rw-r--r--pyanaconda/packaging/yumpayload.py12
2 files changed, 15 insertions, 0 deletions
diff --git a/pyanaconda/packaging/__init__.py b/pyanaconda/packaging/__init__.py
index 65e377685..6462a286d 100644
--- a/pyanaconda/packaging/__init__.py
+++ b/pyanaconda/packaging/__init__.py
@@ -277,6 +277,9 @@ class Payload(object):
def deselectEnvironment(self, environmentid):
raise NotImplementedError()
+ def environmentGroups(self, environmentid):
+ raise NotImplementedError()
+
###
### METHODS FOR WORKING WITH GROUPS
###
diff --git a/pyanaconda/packaging/yumpayload.py b/pyanaconda/packaging/yumpayload.py
index 6f3160dfa..cd2e22ee5 100644
--- a/pyanaconda/packaging/yumpayload.py
+++ b/pyanaconda/packaging/yumpayload.py
@@ -837,6 +837,18 @@ reposdir=%s
for group in environment.options:
self.deselectGroup(group)
+ def environmentGroups(self, environmentid):
+ groups = self._yumGroups
+ if not groups:
+ return []
+
+ with _yum_lock:
+ if not groups.has_environment(environmentid):
+ raise NoSuchGroup(environmentid)
+
+ environment = groups.return_environment(environmentid)
+ return environment.groups + environment.options
+
###
### METHODS FOR WORKING WITH GROUPS
###