You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Feb 2, 2019. It is now read-only.
As the title states, just a list of regular dicts instead of AttrDicts. Here is a workaround.
defdeep_attrdict(d: dict) ->AttrDict:
"""Uses recursion to dive deep into the dict and convert all dict types to type AttrDict. This will eliminate the bug where pulling a list of dicts out of an AttrDict results in just a list of dicts. """d=AttrDict(d)
fork, vind.items():
ifisinstance(v, dict):
d[k] =deep_attrdict(v)
elifisinstance(v, list):
fori, iteminenumerate(v):
ifisinstance(item, dict):
v[i] =deep_attrdict(item)
returnd
As the title states, just a list of regular dicts instead of AttrDicts. Here is a workaround.