>>> THE PROBLEM:
>>> for some reason, wmII's clock isn't being updated.
>>> load average monitor seems fine, it changes.. but the clock just sits
>>> there and shows the time from when I launched wmii.
I think it's a problem with having two defmonitor stanzas, or else
it's a problem with the implementation of the datetime.now() method on
Ubuntu 9.04
I was able to get a working clock by just removing the uptime from the task bar:
@defmonitor
def load(self):
# return re.sub(r'^.*: ', '', call('uptime')).replace(', ', ' ')
# from datetime import datetime
# return datetime.now().strftime('%A, %b %d %I:%M %p')
return call('date')
# @defmonitor
# def time(self):
# from datetime import datetime
# # return datetime.now().strftime('%c')
# return datetime.now().strftime('%A, %b %d %I:%M %p')
Received on Fri Aug 28 2009 - 00:15:35 UTC
This archive was generated by hypermail 2.2.0 : Fri Aug 28 2009 - 00:24:01 UTC