def update_production(self, prod, irradiation=None):
    ip = self.get_production(prod.name)
    self.debug('saving production {}'.format(prod.name))
    params = prod.get_params()
    for (k, v) in params.items():
        self.debug('setting {}={}'.format(k, v))
        setattr(ip, k, v)
    ip.note = prod.note
    self.add(ip.path, commit=False)
    self.commit('updated production {}'.format(prod.name))
def update_production(self, prod, irradiation=None):
    ip = self.get_production(prod.name)
    self.debug('saving production {}'.format(prod.name))
    params = prod.get_params()
    for (k, v) in params.items():
        self.debug('setting {}={}'.format(k, v))
        setattr(ip, k, v)
    ip.note = prod.note
    self.add(ip.path, commit=False)
    self.commit('updated production {}'.format(prod.name))