r5231 - in trunk/cumin: etc python/cumin
by tmckay@fedoraproject.org
Author: tmckay
Date: 2012-02-29 22:07:36 +0000 (Wed, 29 Feb 2012)
New Revision: 5231
Modified:
trunk/cumin/etc/cumin.conf
trunk/cumin/python/cumin/config.py
Log:
Change default value for the "persona" parameter to grid.
Change the corresponding parameter in cumin.conf that controls cumin-data
instances.
BZ796798
Modified: trunk/cumin/etc/cumin.conf
===================================================================
--- trunk/cumin/etc/cumin.conf 2012-02-28 21:27:20 UTC (rev 5230)
+++ trunk/cumin/etc/cumin.conf 2012-02-29 22:07:36 UTC (rev 5231)
@@ -64,14 +64,14 @@
# webs: web
# Default cumin-data configuration at installation.
-# Assumes 'persona' setting in web section is 'default'
+# Assumes 'persona' setting in the web section is 'grid'
# Expiration of samples and vacuuming of the database is handled
# by the data.grid thread.
-datas: data.grid, data.grid-slots, data.grid-submissions, data.sesame, data.other
+datas: data.grid, data.grid-slots, data.grid-submissions, data.sesame
-# If the 'persona' setting in the web section is set to 'grid' then
-# the 'data.other' section name may be omitted from 'datas' as follows.
-#datas: data.grid, data.grid-slots, data.grid-submissions, data.sesame
+# If the 'persona' setting in the web section is set to 'default' then
+# the 'data.other' section should be added as follows.
+#datas: data.grid, data.grid-slots, data.grid-submissions, data.sesame, data.other
# If the 'persona' setting in the web section is set to 'messaging' then
# the 'data.grid*' section names may be omitted from 'datas' as follows.
@@ -94,7 +94,7 @@
# operator-email: [none]
# update-interval: 10
# max-qmf-table-sort: 1000
-# persona: default
+# persona: grid
#notification-timeout: 180
# Number of seconds that a message in the yellow notification banner
@@ -229,10 +229,10 @@
# [web]
-# persona: default
+# persona: grid
# Controls content of the top level page.
# Valid values are "default", "grid", and "messaging".
-# The default persona contains content for both grid and
+# The "default" persona contains content for both grid and
# messaging.
# [data]
Modified: trunk/cumin/python/cumin/config.py
===================================================================
--- trunk/cumin/python/cumin/config.py 2012-02-28 21:27:20 UTC (rev 5230)
+++ trunk/cumin/python/cumin/config.py 2012-02-29 22:07:36 UTC (rev 5231)
@@ -50,7 +50,7 @@
param.default = 5 * 1024 #MB
param = ConfigParameter(web, "persona", str)
- param.default = "default"
+ param.default = "grid"
param = ConfigParameter(web, "fast-view-attributes", str)
param.default = "JobStatus,Cmd,Args,ExitStatus,JobStartDate,LastRemoteHost,LastJobStatus,Owner"
12 years, 2 months
r5229 - in trunk/cumin/python/cumin: grid inventory
by croberts@fedoraproject.org
Author: croberts
Date: 2012-02-24 19:31:11 +0000 (Fri, 24 Feb 2012)
New Revision: 5229
Modified:
trunk/cumin/python/cumin/grid/slot.strings
trunk/cumin/python/cumin/inventory/system.py
trunk/cumin/python/cumin/inventory/system.strings
Log:
Addressing BZ 772105 by adjusting the HTML and CSS for the display of the slotvis and legend on the Inventory-> System page.
Modified: trunk/cumin/python/cumin/grid/slot.strings
===================================================================
--- trunk/cumin/python/cumin/grid/slot.strings 2012-02-24 19:26:56 UTC (rev 5228)
+++ trunk/cumin/python/cumin/grid/slot.strings 2012-02-24 19:31:11 UTC (rev 5229)
@@ -369,7 +369,7 @@
background-image: url(resource?name=shade1.png);
}
div.SlotLegend {
- margin: 0 0 0 8em;
+ margin: 0 0 0 2em;
width: 12em;
}
div.SlotLegend dl {
Modified: trunk/cumin/python/cumin/inventory/system.py
===================================================================
--- trunk/cumin/python/cumin/inventory/system.py 2012-02-24 19:26:56 UTC (rev 5228)
+++ trunk/cumin/python/cumin/inventory/system.py 2012-02-24 19:31:11 UTC (rev 5229)
@@ -267,10 +267,10 @@
return sess.marshal()
def render_slot_chart_width(self, session):
- return 400
+ return 250
def render_slot_chart_height(self, session):
- return 400
+ return 250
class SystemSlotMapPage(SlotMapPage):
def __init__(self, app, name):
Modified: trunk/cumin/python/cumin/inventory/system.strings
===================================================================
--- trunk/cumin/python/cumin/inventory/system.strings 2012-02-24 19:26:56 UTC (rev 5228)
+++ trunk/cumin/python/cumin/inventory/system.strings 2012-02-24 19:31:11 UTC (rev 5229)
@@ -49,12 +49,26 @@
visibility: hidden;
}
+.system_slot_legend {
+ float: right;
+ width: 150px;
+}
+
+.system_slot_vis {
+ float: left;
+ width: 250px;
+}
+
[SystemSlotFlashVis.html]
<div id="SystemSlotFlashVis">
<h2>Slots</h2>
- <div class="StatValueChart" id="{id}">
- <div id="{id}_chart"></div>
- {slot_legend}
+ <div class="StatValueChart SlotVisChart {fullpageable}" id="{id}">
+ <h2>{title}</h2>
+ <div class="slot_visualization">
+ <div class="system_slot_vis" id="{id}_chart"></div>
+ <div class="slot_legend system_slot_legend">{slot_legend}</div>
+ </div>
+ <div style="clear:both;"></div>
</div>
</div>
<script type="text/javascript">
12 years, 2 months
r5228 - trunk/cumin/python/cumin/grid
by croberts@fedoraproject.org
Author: croberts
Date: 2012-02-24 19:26:56 +0000 (Fri, 24 Feb 2012)
New Revision: 5228
Modified:
trunk/cumin/python/cumin/grid/slot.py
Log:
Referencing the newly slimmed down version of charts.py for the slotvis.
Modified: trunk/cumin/python/cumin/grid/slot.py
===================================================================
--- trunk/cumin/python/cumin/grid/slot.py 2012-02-24 19:25:52 UTC (rev 5227)
+++ trunk/cumin/python/cumin/grid/slot.py 2012-02-24 19:26:56 UTC (rev 5228)
@@ -10,6 +10,7 @@
from cumin.stat import *
from cumin.widgets import *
from cumin.OpenFlashChart import *
+from cumin.charts import *
strings = StringCatalog(__file__)
log = logging.getLogger("cumin.slot")
12 years, 2 months
r5227 - trunk/cumin/python/cumin
by croberts@fedoraproject.org
Author: croberts
Date: 2012-02-24 19:25:52 +0000 (Fri, 24 Feb 2012)
New Revision: 5227
Added:
trunk/cumin/python/cumin/charts.py
Log:
Adding a slimmed down version of charts.py back so that we can maintain the slotvis for the time being.
Added: trunk/cumin/python/cumin/charts.py
===================================================================
--- trunk/cumin/python/cumin/charts.py (rev 0)
+++ trunk/cumin/python/cumin/charts.py 2012-02-24 19:25:52 UTC (rev 5227)
@@ -0,0 +1,139 @@
+import logging
+
+from cairo import *
+from random import random
+from time import time
+from math import sqrt, pi, ceil
+
+from formats import *
+from util import *
+
+log = logging.getLogger("cumin.chart")
+
+
+class HeatMapChart(object):
+ def __init__(self, width=400, height=400):
+ self.width = width # final width
+ self.height = height
+ self.max_width = width # max width
+ self.max_height = height
+ self.cols = 0 # columns
+ self.rows = 0
+ self.max_size = 28 # size of each slot
+ self.surface = None
+ self.gap = 3
+
+ def plot_colored_shape(self, interior, shape, width, height):
+ surface = ImageSurface(FORMAT_ARGB32, int(width), int(height))
+ cr = Context(surface)
+ cr.set_line_width(1)
+
+ cr.set_source_rgba(1.0, 1.0, 1.0, 1.0)
+ cr.rectangle(0, 0, width - 1, height - 1)
+ cr.fill()
+
+ cr.set_line_width(2)
+ self._plot_shape(cr, interior, shape, 0, 0, width, height)
+ return surface
+
+ def plot_colored_rect(self, interior, width, height):
+ surface = ImageSurface(FORMAT_ARGB32, int(width), int(height))
+ cr = Context(surface)
+ cr.set_line_width(1)
+
+ cr.set_source_rgb(*interior)
+ cr.rectangle(0, 0, width - 1, height - 1)
+ cr.fill()
+ return surface
+
+ def plot_state(self, state, width, height):
+ surface = ImageSurface(FORMAT_ARGB32, int(width), int(height))
+ cr = Context(surface)
+ cr.set_line_width(2)
+
+ self._plot_square(cr, (0.7, 0.7, 0.7), state, 0, 0, width, height)
+ return surface
+
+ def _plot_square(self, cr, colors, state, x, y, width, height):
+ if state == "Unclaimed":
+ shape = "box"
+ elif state == "Claimed":
+ shape = "solid"
+ elif state in ("Owner", "Unavailable"):
+ shape = "diagonal"
+ elif state in ("Matched", "Preempting", "Preempting/Matched"):
+ shape = "filled_triangle"
+ else:
+ shape = "box"
+
+ self._plot_shape(cr, colors, shape, x, y, width, height)
+
+ def _plot_shape(self, cr, colors, shape, x, y, width, height):
+ cr.set_source_rgb(*colors)
+ #cr.move_to(x, y)
+ cr.rectangle(x, y, width - self.gap, height - self.gap)
+
+ if shape == "box": # leave empty
+ cr.stroke()
+ elif shape == "solid": # solid fill
+ cr.fill()
+ elif shape == "diagonal": # diagonal line
+ cr.move_to(x, y)
+ cr.line_to(x + width - self.gap, y + height - self.gap)
+ cr.stroke()
+ elif shape == "filled_triangle": # triangle
+ cr.stroke()
+ cr.move_to(x + width - self.gap, y)
+ cr.line_to(x, y + height - self.gap)
+ cr.line_to(x + width - self.gap, y + height - self.gap)
+ cr.close_path()
+ cr.fill()
+
+ def plot_shapes(self, shape_info, zl):
+ count = len(shape_info)
+ slot_size = self.slot_size(count, zl)
+ x = 0
+ y = 0
+ col = 0
+ self.rows = 1
+ # the width and height depend on the number of slots
+ self.surface = ImageSurface(FORMAT_ARGB32, int(self.width), int(self.height))
+ cr = Context(self.surface)
+
+ cr.set_line_width( zl == 1 and 1 or 2 )
+
+ for slot in shape_info:
+ interior = slot["color"]
+ shape = slot["shape"]
+
+ if col >= self.cols:
+ x = 0
+ y = y + slot_size
+ col = 0
+ self.rows = self.rows + 1
+
+ self._plot_shape(cr, interior, shape, x, y, slot_size, slot_size)
+
+ x = x + slot_size
+ col = col + 1
+ return slot_size
+
+ def slot_size(self, count, zoom=1):
+ sq = sqrt(count)
+ cols = int(sq)
+ if sq > cols:
+ cols = cols + 1
+ size = int(self.width * zoom / cols)
+ if size < 2:
+ size = 2
+ if size > self.max_size * zoom:
+ size = self.max_size * zoom
+
+ self.width = int((size * cols) + 1)
+ self.height = int((ceil(count * 1.0 / cols) * size) + 1)
+ self.cols = cols
+ return size
+
+ def write(self, writer):
+ self.surface.write_to_png(writer)
+
Property changes on: trunk/cumin/python/cumin/charts.py
___________________________________________________________________
Added: svn:mime-type
+ text/plain
12 years, 2 months
r5226 - in trunk/cumin: etc python/cumin
by croberts@fedoraproject.org
Author: croberts
Date: 2012-02-23 20:21:39 +0000 (Thu, 23 Feb 2012)
New Revision: 5226
Modified:
trunk/cumin/etc/cumin.conf
trunk/cumin/python/cumin/widgets.py
Log:
Addressing BZ 750196 again by adding a case for a value of 0 (or less) to cause the messages to never timeout (which was the original cumin behavior).
Modified: trunk/cumin/etc/cumin.conf
===================================================================
--- trunk/cumin/etc/cumin.conf 2012-02-23 20:09:59 UTC (rev 5225)
+++ trunk/cumin/etc/cumin.conf 2012-02-23 20:21:39 UTC (rev 5226)
@@ -98,7 +98,8 @@
#notification-timeout: 180
# Number of seconds that a message in the yellow notification banner
-# will exist before being automatically dismissed. Default is 180 seconds
+# will exist before being automatically dismissed. Default is 180 seconds.
+# A value of 0 will cause the messages to never timeout
[data]
# log-file: $CUMIN_HOME/log/data.log
Modified: trunk/cumin/python/cumin/widgets.py
===================================================================
--- trunk/cumin/python/cumin/widgets.py 2012-02-23 20:09:59 UTC (rev 5225)
+++ trunk/cumin/python/cumin/widgets.py 2012-02-23 20:21:39 UTC (rev 5226)
@@ -1217,12 +1217,13 @@
def get_items(self, session):
items = session.get_notifications()
- for i in items:
- # we want the messages to timeout after 3 min, the easiest way is to dismiss it
- # doing it here for now so that both TaskInvocations and Notifications will be handled in the same place.
- # The value for the timeout can be changed via the notification-timeout config
- if not i.dismissed and datetime.now() - i.timestamp >= timedelta(seconds=self.app.notification_timeout):
- i.dismissed = True
+ if self.app.notification_timeout > 0:
+ for i in items:
+ # we want the messages to timeout after 3 min, the easiest way is to dismiss it
+ # doing it here for now so that both TaskInvocations and Notifications will be handled in the same place.
+ # The value for the timeout can be changed via the notification-timeout config
+ if not i.dismissed and datetime.now() - i.timestamp >= timedelta(seconds=self.app.notification_timeout):
+ i.dismissed = True
items = [x for x in items if not x.dismissed]
return items
12 years, 2 months
r5225 - in trunk/cumin: bin etc python/cumin
by croberts@fedoraproject.org
Author: croberts
Date: 2012-02-23 20:09:59 +0000 (Thu, 23 Feb 2012)
New Revision: 5225
Modified:
trunk/cumin/bin/cumin-web
trunk/cumin/etc/cumin.conf
trunk/cumin/python/cumin/config.py
trunk/cumin/python/cumin/widgets.py
Log:
Addressing BZ 750196 by adding an optional config entry for the number of seconds before a notification in the yellow banner will exist before being dismissed. The default value is 180 seocnds (3 minutes).
Modified: trunk/cumin/bin/cumin-web
===================================================================
--- trunk/cumin/bin/cumin-web 2012-02-21 19:42:04 UTC (rev 5224)
+++ trunk/cumin/bin/cumin-web 2012-02-23 20:09:59 UTC (rev 5225)
@@ -139,6 +139,8 @@
cumin.user = values.user
cumin.update_interval = values.update_interval
cumin.max_qmf_table_sort = values.max_qmf_table_sort
+
+ cumin.notification_timeout = values.notification_timeout
cumin.fast_view_attributes = [x.strip() for x in values.fast_view_attributes.split(',')]
Modified: trunk/cumin/etc/cumin.conf
===================================================================
--- trunk/cumin/etc/cumin.conf 2012-02-21 19:42:04 UTC (rev 5224)
+++ trunk/cumin/etc/cumin.conf 2012-02-23 20:09:59 UTC (rev 5225)
@@ -96,6 +96,10 @@
# max-qmf-table-sort: 1000
# persona: default
+#notification-timeout: 180
+# Number of seconds that a message in the yellow notification banner
+# will exist before being automatically dismissed. Default is 180 seconds
+
[data]
# log-file: $CUMIN_HOME/log/data.log
# expire-enabled: True
Modified: trunk/cumin/python/cumin/config.py
===================================================================
--- trunk/cumin/python/cumin/config.py 2012-02-21 19:42:04 UTC (rev 5224)
+++ trunk/cumin/python/cumin/config.py 2012-02-23 20:09:59 UTC (rev 5225)
@@ -54,6 +54,9 @@
param = ConfigParameter(web, "fast-view-attributes", str)
param.default = "JobStatus,Cmd,Args,ExitStatus,JobStartDate,LastRemoteHost,LastJobStatus,Owner"
+
+ param = ConfigParameter(web, "notification-timeout", int)
+ param.default = 180
def create_data_section(self, name, strict_section):
data = CuminConfigSection(self, name, strict_section)
@@ -175,7 +178,7 @@
param = ConfigParameter(self, "aviary-domain-verify", bool)
param.default = True
-
+
# Intended for development use, not the end user.
# Undocumented.
param = ConfigParameter(self, "aviary-suds-logs", bool)
Modified: trunk/cumin/python/cumin/widgets.py
===================================================================
--- trunk/cumin/python/cumin/widgets.py 2012-02-21 19:42:04 UTC (rev 5224)
+++ trunk/cumin/python/cumin/widgets.py 2012-02-23 20:09:59 UTC (rev 5225)
@@ -14,7 +14,6 @@
from task import *
from user import *
from util import *
-
import time
from wooly import Session
@@ -1217,7 +1216,14 @@
self.add_child(self.item_widget)
def get_items(self, session):
- items = [x for x in session.get_notifications() if not x.dismissed]
+ items = session.get_notifications()
+ for i in items:
+ # we want the messages to timeout after 3 min, the easiest way is to dismiss it
+ # doing it here for now so that both TaskInvocations and Notifications will be handled in the same place.
+ # The value for the timeout can be changed via the notification-timeout config
+ if not i.dismissed and datetime.now() - i.timestamp >= timedelta(seconds=self.app.notification_timeout):
+ i.dismissed = True
+ items = [x for x in items if not x.dismissed]
return items
def do_process(self, session):
12 years, 2 months
r5224 - trunk/cumin/python/cumin/grid
by tmckay@fedoraproject.org
Author: tmckay
Date: 2012-02-21 19:42:04 +0000 (Tue, 21 Feb 2012)
New Revision: 5224
Modified:
trunk/cumin/python/cumin/grid/submission.py
Log:
Add a validation check on submission descriptions that disallows double quotes.
Modified: trunk/cumin/python/cumin/grid/submission.py
===================================================================
--- trunk/cumin/python/cumin/grid/submission.py 2012-02-17 00:27:09 UTC (rev 5223)
+++ trunk/cumin/python/cumin/grid/submission.py 2012-02-21 19:42:04 UTC (rev 5224)
@@ -216,6 +216,14 @@
def render_help(self, session):
return "This text will identify the submission"
+ def validate(self, session):
+ super(JobDescriptionField, self).validate(session)
+
+ des = self.get(session)
+ if '"' in des:
+ error = FormError("Double quotes are not allowed in submission descriptions")
+ self.form.errors.add(session, error)
+
class JobSchedulerField(ScalarField):
def __init__(self, app, name):
super(JobSchedulerField, self).__init__(app, name, None)
12 years, 2 months
r5223 - in trunk: cumin/python/cumin sage/python/sage sage/python/sage/aviary sage/python/sage/qmf
by tmckay@fedoraproject.org
Author: tmckay
Date: 2012-02-17 00:27:09 +0000 (Fri, 17 Feb 2012)
New Revision: 5223
Modified:
trunk/cumin/python/cumin/model.py
trunk/sage/python/sage/aviary/aviaryoperations.py
trunk/sage/python/sage/qmf/qmfoperations.py
trunk/sage/python/sage/util.py
Log:
Change level to DEBUG from ERROR in CallSync when methods return non-zero status.
Add the name of the method being invoked and the data returned.
Messages will now be suppressed under INFO level logging. Any additional logging can
be done in the caller as needed.
BZ782539 (but applies generally, not just to HFS quota)
Modified: trunk/cumin/python/cumin/model.py
===================================================================
--- trunk/cumin/python/cumin/model.py 2012-02-16 16:58:34 UTC (rev 5222)
+++ trunk/cumin/python/cumin/model.py 2012-02-17 00:27:09 UTC (rev 5223)
@@ -663,7 +663,8 @@
def execute(self, remote, negotiator, groups, prepend=""):
default = {'Value': 0}
for group in groups:
- sync = self.syncs.add_sync(group, default)
+ sync = self.syncs.add_sync(group, default,
+ remote.get_raw_config.__name__)
try:
remote.get_raw_config(negotiator, prepend+group, sync.get_completion())
except Exception, e:
Modified: trunk/sage/python/sage/aviary/aviaryoperations.py
===================================================================
--- trunk/sage/python/sage/aviary/aviaryoperations.py 2012-02-16 16:58:34 UTC (rev 5222)
+++ trunk/sage/python/sage/aviary/aviaryoperations.py 2012-02-17 00:27:09 UTC (rev 5223)
@@ -628,19 +628,21 @@
return result
def _call_sync(self, process_results, meth, *meth_args, **meth_kwargs):
- # Common interface with QMF operations requires that a MethodResult
- # object (or something just like it) be returned for synchronous calls.
- # Might as well use the CallSync since the completion() routine
- # handles status semantics.
- sync = CallSync()
- try:
- result = meth(*meth_args, **meth_kwargs)
- except Exception, e:
- result = e
- cb_args = process_results(result)
- sync.get_completion()(*cb_args)
- return sync
+ # Common interface with QMF operations requires that a MethodResult
+ # object (or something just like it) be returned for synchronous calls.
+ # Might as well use the CallSync since the completion() routine
+ # handles status semantics.
+ # meth here is a suds.client.Method which has a name attr....
+ sync = CallSync(log, name=meth.method.name)
+ try:
+ result = meth(*meth_args, **meth_kwargs)
+ except Exception, e:
+ result = e
+ cb_args = process_results(result)
+ sync.get_completion()(*cb_args)
+ return sync
+
class AviaryOperations(_AviaryCommon, _AviaryJobMethods, _AviaryQueryMethods):
def __init__(self, name, datadir, job_servers, query_servers,
key="", cert="", root_cert="", domain_verify=True):
Modified: trunk/sage/python/sage/qmf/qmfoperations.py
===================================================================
--- trunk/sage/python/sage/qmf/qmfoperations.py 2012-02-16 16:58:34 UTC (rev 5222)
+++ trunk/sage/python/sage/qmf/qmfoperations.py 2012-02-17 00:27:09 UTC (rev 5223)
@@ -236,7 +236,7 @@
self.session.call_method(cb, obj, meth, args)
else:
try:
- sync = CallSync(log, dflt)
+ sync = CallSync(log, dflt, meth)
self.session.call_method(sync.get_completion(),
obj, meth, args)
except Exception, e:
Modified: trunk/sage/python/sage/util.py
===================================================================
--- trunk/sage/python/sage/util.py 2012-02-16 16:58:34 UTC (rev 5222)
+++ trunk/sage/python/sage/util.py 2012-02-17 00:27:09 UTC (rev 5223)
@@ -32,10 +32,11 @@
of the 'completion'.
The 'done' method can be polled to determine if the operation has completed.
'''
- def __init__(self, log=None, default=None):
+ def __init__(self, log=None, default=None, name=""):
super(CallSync, self).__init__()
self.data = default
self.log = log
+ self.meth = name
def get_completion(self):
# Note that because of the way binding is done in Python,
@@ -45,6 +46,11 @@
# function without an object reference (the reference is hidden
# inside the bound function). Formally known as a "closure"
+ def log_debug(self, status, data):
+ if self.log:
+ self.log.debug("CallSync: method '%s' returned "\
+ "status '%s' and data '%s'" % (self.meth, status, data))
+
def completion(*args):
# Callback argument formats come in two basic flavors in Cumin
# depending on the semantics of the async op:
@@ -52,12 +58,10 @@
# callback(result) where type(result) == Exception indicates
# a failure status
# Allow this general mechanism to handle both types.
-
data = None
if len(args) == 0:
# Just call it successful with no data
status = 0
-
elif len(args) == 1:
status = args[0]
if not isinstance(status, Exception):
@@ -72,9 +76,7 @@
self.got_data = True
else:
self.error = Exception(status)
- msg = "CallSync: call returned with status of %s" % str(status)
- if self.log is not None:
- self.log.error(msg)
+ log_debug(self, status, data)
return completion
def done(self):
@@ -92,8 +94,8 @@
self.timeout = timeout
self.log = log
- def add_sync(self, key, default=None):
- sync = CallSync(self.log, default)
+ def add_sync(self, key, default=None, name=""):
+ sync = CallSync(self.log, default, name)
self.syncs[key] = sync
return sync
12 years, 2 months
r5222 - in trunk/cumin: python/cumin/grid resources
by croberts@fedoraproject.org
Author: croberts
Date: 2012-02-16 16:58:34 +0000 (Thu, 16 Feb 2012)
New Revision: 5222
Added:
trunk/cumin/resources/slotvis-Available.png
trunk/cumin/resources/slotvis-Paused.png
trunk/cumin/resources/slotvis-Running.png
trunk/cumin/resources/slotvis-Starting.png
trunk/cumin/resources/slotvis-Stopping.png
trunk/cumin/resources/slotvis-Unavailable.png
Modified:
trunk/cumin/python/cumin/grid/slot.py
Log:
Fixing up the slotvis legend icons.
Modified: trunk/cumin/python/cumin/grid/slot.py
===================================================================
--- trunk/cumin/python/cumin/grid/slot.py 2012-02-15 18:17:21 UTC (rev 5221)
+++ trunk/cumin/python/cumin/grid/slot.py 2012-02-16 16:58:34 UTC (rev 5222)
@@ -573,4 +573,4 @@
params = list()
params.append("category=%s" % cat)
- return "poolslots.vis?" + ";".join(params)
+ return "resource?name=slotvis-" + cat + ".png"
Added: trunk/cumin/resources/slotvis-Available.png
===================================================================
(Binary files differ)
Property changes on: trunk/cumin/resources/slotvis-Available.png
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/cumin/resources/slotvis-Paused.png
===================================================================
(Binary files differ)
Property changes on: trunk/cumin/resources/slotvis-Paused.png
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/cumin/resources/slotvis-Running.png
===================================================================
(Binary files differ)
Property changes on: trunk/cumin/resources/slotvis-Running.png
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/cumin/resources/slotvis-Starting.png
===================================================================
(Binary files differ)
Property changes on: trunk/cumin/resources/slotvis-Starting.png
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/cumin/resources/slotvis-Stopping.png
===================================================================
(Binary files differ)
Property changes on: trunk/cumin/resources/slotvis-Stopping.png
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/cumin/resources/slotvis-Unavailable.png
===================================================================
(Binary files differ)
Property changes on: trunk/cumin/resources/slotvis-Unavailable.png
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
12 years, 2 months
r5221 - trunk/wooly/python/wooly
by croberts@fedoraproject.org
Author: croberts
Date: 2012-02-15 18:17:21 +0000 (Wed, 15 Feb 2012)
New Revision: 5221
Modified:
trunk/wooly/python/wooly/__init__.py
Log:
Fixing the timestamps for Notifications. This is required to fully address BZ 787138
Modified: trunk/wooly/python/wooly/__init__.py
===================================================================
--- trunk/wooly/python/wooly/__init__.py 2012-02-14 20:13:05 UTC (rev 5220)
+++ trunk/wooly/python/wooly/__init__.py 2012-02-15 18:17:21 UTC (rev 5221)
@@ -852,9 +852,11 @@
message = message.capitalize()
self.message = message
self.preamble = preamble
+ self.timestamp = datetime.now() #may want a superclass since this is duplicated in TaskInvocation
def get_message(self, session):
- return "%s: %s" % (self.preamble, self.message)
+ timestamp = "%s-%02d-%02d %02d:%02d:%02d" % (self.timestamp.year, self.timestamp.month, self.timestamp.day, self.timestamp.hour, self.timestamp.minute, self.timestamp.second)
+ return "<span class='notification_time'>%s</span> %s: %s" % (timestamp, self.preamble, self.message)
class SessionAttribute(object):
def __init__(self, widget, name):
12 years, 2 months