QueryBuilder.update()
does not respect model __casts__
#831
Labels
enhancement
A feature that exists, works as intended but needs to be improved
feature request
A feature that does not yet exist but will be a good addition to the library
Describe the feature as you'd like to see it
In my code I rely on models casts for some fields. As far as I can see it's implemented everywhere in model methods, but querybuilder ones.
It would be really nice to have consistent behavior over all Model/QueryBuilder methods.
In order for change to be non breaking I suggest to add
cast=False
kwarg toQueryBuilder.update()
to preserve current state of things by default.What do we currently have to do now?
To be exact:
I have to call
Model.update(..)
with some uglyjson.dumps(...)
inside while havingjson
casts enabled in model.The text was updated successfully, but these errors were encountered: