[issue35540] dataclasses.asdict breaks with defaultdict fields

Rémi Lapeyre report at bugs.python.org
Sat Dec 29 20:25:41 EST 2018


Rémi Lapeyre <remi.lapeyre at henki.fr> added the comment:

Hi @wrmsr, this happens because the constructor for `collections.defaultdict` differs from the one of `dict`.

I think the argument that collections.defaultdict is in the stdlib and should be supported is right, the changes in PR #11361 should do what you want.

----------
nosy: +remi.lapeyre

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue35540>
_______________________________________


More information about the Python-bugs-list mailing list