In lab, there was some confusion about how to change a setable, as it is has some differences from working with tunes. Namely, there is no safeguarding alterations to setables--they can be freely changed on an instrument without calling an associated transition or recording its history. Perhaps unintentionally, changing a setable is not considered an update to an instrument, and so you cannot update an instrument by just changing the setable value.
For now, we think the best practice is to wrap the change with an update_merge, that is:
new = attune.Instrument(**old.as_dict())
new.setables["SHG_Crystall"] = 42
newer = attune.update_merge(old, new)
attune.store(newer)
In lab, there was some confusion about how to change a setable, as it is has some differences from working with tunes. Namely, there is no safeguarding alterations to setables--they can be freely changed on an instrument without calling an associated transition or recording its history. Perhaps unintentionally, changing a setable is not considered an update to an instrument, and so you cannot update an instrument by just changing the setable value.
For now, we think the best practice is to wrap the change with an update_merge, that is: