The bug was due to python's evaluation of default arguments at
definition time. This was causing the addition of time/steps/etc..
to the values of the day widget was added instead of the current
day's values.
def get_values(self):
return self.values
def get_values(self):
return self.values
- def add_values(self, values, when=date.today()):
+ def add_values(self, values, when=None):
+ if when is None:
+ when = date.today()
"""add PedoValues values to repository """
try:
self.values[when] = self.values[when] + values
"""add PedoValues values to repository """
try:
self.values[when] = self.values[when] + values