Author: croberts
Date: 2012-10-15 15:14:27 +0000 (Mon, 15 Oct 2012)
New Revision: 5509
Modified:
trunk/cumin/python/cumin/grid/negotiator.py
Log:
Addressing problem with rendering the values for the quota editing pie chart. Previously,
if a group was looked for, but not there (perhaps correctly so), we were silently failing
instead of silently continuing.
Modified: trunk/cumin/python/cumin/grid/negotiator.py
===================================================================
--- trunk/cumin/python/cumin/grid/negotiator.py 2012-10-12 20:53:09 UTC (rev 5508)
+++ trunk/cumin/python/cumin/grid/negotiator.py 2012-10-15 15:14:27 UTC (rev 5509)
@@ -308,10 +308,12 @@
info = self.group_helper.get_config_for_groups(session,
"GROUP_QUOTA_DYNAMIC", groups)
values = []
dynamic_groups = []
- try:
- dynamic_groups = ["%s" % x for x in groups if
info[x]["GROUP_QUOTA_DYNAMIC"] != ""]
- except:
- log.error("Error when loading dynamic group values for quota
editing.")
+ for x in groups:
+ try:
+ if info[x]["GROUP_QUOTA_DYNAMIC"] != "":
+ dynamic_groups.append(x)
+ except Exception, e:
+ pass
for group in sorted(groups):
if(group in dynamic_groups):
values.append(self.render_quota_value(session, group))
@@ -327,10 +329,12 @@
info = self.group_helper.get_config_for_groups(session,
"GROUP_QUOTA_DYNAMIC", groups)
values = []
dynamic_groups = []
- try:
- dynamic_groups = ["%s" % x for x in groups if
info[x]["GROUP_QUOTA_DYNAMIC"] != ""]
- except:
- log.error("Error when loading dynamic group names for quota
editing.")
+ for x in groups:
+ try:
+ if info[x]["GROUP_QUOTA_DYNAMIC"] != "":
+ dynamic_groups.append(x)
+ except Exception, e:
+ pass
for group in sorted(groups):
if(group in dynamic_groups):
values.append(group)
Show replies by date