[Feature]: Call set_modified at the end of field setter methods to make appending easier
What would you like to see added to HDMF?
Currently, when appending a group or dataset (and probably also links and maybe attributes?) to existing files, the user needs to open the file in append mode, set the field that doesn't exist yet on the parent container, and call AbstractContainer.set_modified on the parent container, and then call io.write(file). Calling set_modified seems like an unnecessary extra step for the user. It should just be called every time a field is set to a new value.
See https://github.com/NeurodataWithoutBorders/pynwb/pull/2032#issuecomment-2641001159
What solution would you like?
Change the field setter in AbstractContainer: https://github.com/hdmf-dev/hdmf/blob/dev/src/hdmf/container.py#L83-L91
to call self.set_modified() at the end.
Do you have any interest in helping implement the feature?
Yes.
@rly Is this something we want to implement for the next release?
Yes