[yum-cvs] yum/yum __init__.py,1.163,1.164 constants.py,1.6,1.7

Seth Vidal skvidal at login.linux.duke.edu
Wed Dec 7 16:51:38 UTC 2005


Update of /home/groups/yum/cvs/yum/yum
In directory login:/tmp/cvs-serv23274/yum

Modified Files:
	__init__.py constants.py 
Log Message:
add TS_INSTALL_STATES and TS_REMOVE STATES into constants
use them in deselectGroup()



Index: __init__.py
===================================================================
RCS file: /home/groups/yum/cvs/yum/yum/__init__.py,v
retrieving revision 1.163
retrieving revision 1.164
diff -u -r1.163 -r1.164
--- __init__.py	7 Dec 2005 16:49:01 -0000	1.163
+++ __init__.py	7 Dec 2005 16:51:36 -0000	1.164
@@ -1284,8 +1284,7 @@
         for pkgname in thisgroup.packages:
         
             for txmbr in self.tsInfo:
-                if txmbr.po.name == pkgname and txmbr.po.state in [TS_INSTALL,
-                                                    TS_UPDATE, TS_OBSOLETING]:
+                if txmbr.po.name == pkgname and txmbr.po.state in TS_INSTALL_STATES:
                     try: 
                         txmbr.groups.remove(grpid)
                     except ValueError:

Index: constants.py
===================================================================
RCS file: /home/groups/yum/cvs/yum/yum/constants.py,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- constants.py	4 Oct 2005 18:48:29 -0000	1.6
+++ constants.py	7 Dec 2005 16:51:36 -0000	1.7
@@ -23,6 +23,10 @@
 TS_OBSOLETING = 60
 TS_AVAILABLE = 70
 
+
+TS_INSTALL_STATES = [TS_INSTALL, TS_TRUEINSTALL, TS_UPDATE, TS_OBSOLETING]
+TS_REMOVE_STATES = [TS_ERASE, TS_OBSOLETED]
+
 # Transaction Relationships
 TR_UPDATES = 1
 TR_UPDATEDBY = 2




More information about the Yum-cvs-commits mailing list