Closed dlopes7 closed 5 years ago
@dlopes7 I find this issue too and fix it .There is a breaking change in marshmallow 3 :
https://marshmallow.readthedocs.io/en/stable/changelog.html#rc7-2019-06-15
Backwards-incompatible: many is passed as a keyword argument to methods decorated with pre_load, post_load, pre_dump, post_dump, and validates_schema. partial is passed as a keyword argument to methods decorated with pre_load, post_load and validates_schema. **kwargs should be added to all decorated methods.
So you need to change all pre/post function. e.g. `
# original one : def dump_user(self,data)
def dump_user(self, data, **kwargs):
return {'user': data}
`
@mohamed-aziz @alessandrojcm Based on issue described above , could you please accept my PR(this is only part of fix , and I will finalize more later)
@Allianzcortex I merged your PR, could you fix the code so that it passes the failed unit tests? unfortunately I have no time to work on this.
@mohamed-aziz Sure ! No Problem ! it seems strange for the code logic remains the same and error information is about type annotation
I will fix it soon(with other changes in pre/post function)
@Allianzcortex I'm not sure what the problem seems to be, take your time with this. I don't think this is related to this issue. Maybe we should open a new issue? because this was fixed by your last commit.
You should specify on requirements that marshmallow 2 is enforced, or update the app to be compatible with marshmallow 3