fedora-vote newelection.py,1.4,1.5 voting.py,1.10,1.11

Toshio Ernie Kuratomi (toshio) fedora-extras-commits at redhat.com
Tue Oct 3 00:51:54 UTC 2006


Author: toshio

Update of /cvs/fedora/fedora-vote
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv9687

Modified Files:
	newelection.py voting.py 
Log Message:
* newelection.py: Set up the Fedora Ambassadors election.
* voting.py: Fix detection of double votes.  The code needed to detect
  votes per person *per election* rather than votes per person in any
  election.



Index: newelection.py
===================================================================
RCS file: /cvs/fedora/fedora-vote/newelection.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- newelection.py	21 Jun 2006 04:53:36 -0000	1.4
+++ newelection.py	3 Oct 2006 00:51:51 -0000	1.5
@@ -14,31 +14,39 @@
 dbHost = 'db1.fedora.phx.redhat.com'
 dbUser = 'electionsuser'
 
-electionName = 'FESCo 2006'
-start = '2006-06-22 00:00:00'
-end = '2006-07-02 23:59:59'
-seats = '13'
-
-votingGroups = ('cvsextras',)
-
-candidates = ('awjb',
-    'jwboyer',
-    'spot',
-    'rdieter',
-    'kevin',
-    'ausil',
-    'c4chris',
-    'katzj',
-    'mjk',
-    'toshio',
-    'thl',
-    'jpo',
-    'bpepple',
-    'mschwendt',
-    'scop',
-    'tibbs',
-    'wtogami',
-    'skvidal')
+electionName = 'Fedora Ambassadors 2006'
+start = '2006-09-21 00:00:00'
+end = '2006-09-27 23:59:59'
+#start = '2006-09-29 00:00:00'
+#end = '2006-10-05 23:59:59'
+seats = '7'
+
+votingGroups = ('ambassadors',)
+
+candidates = (
+    # Alex Maier
+    'amaier',
+    # Charles VINCHON
+    'cvinchon',
+    # Damien Durand
+    'splinux',
+    # David Nalley
+    'ke4qqq',
+    # Francesco Ugolini
+    'wmirror',
+    # Jack Aboutboul
+    'jaboutboul',
+    # Jeffrey Tadlock
+    'jeffreyt',
+    # Patrick W. Barnes
+    'nman64',
+    # Robert Whetsel
+    'rwhetsel',
+    # Rodrigo Padula
+    'rodrigop',
+    # Thomas Chung
+    'tchung'
+    )
 groupList = []
 candList = []
 


Index: voting.py
===================================================================
RCS file: /cvs/fedora/fedora-vote/voting.py,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- voting.py	22 Jun 2006 02:51:01 -0000	1.10
+++ voting.py	3 Oct 2006 00:51:51 -0000	1.11
@@ -137,7 +137,7 @@
                     ' accounts db' % username
 
         # Ask the voting db whether the userId has already voted
-        self.dbCmd.execute("select id from ballots where voter = '%s'" % userId)
+        self.dbCmd.execute("select id from ballots where voter = '%s' and election_id = '%s'" % (userId, self.electionId))
         if self.dbCmd.fetchall():
             return True
         return False




More information about the scm-commits mailing list