I've been having some issues with Django model saving and concurrency.
It seems unnecessary that every time you call .save()
on a model it overwrites every field even if you're only intending to write one field. I can't think of a specific use case for why that would be the default behavior since it is safer for concurrency and more performant to only write the necessary fields.
I was thinking about expanding off of this thread to automatically determine which fields have been updated to specify update_fields
(if they aren't already specified) accordingly in the save method.
Has anyone tried this? Am I overlooking something that will cause other issues?