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
… /site-packages/easydict/__init__.py", line 122, in __init__
setattr(self, k, v)
TypeError: attribute name must be string, not 'tuple'
Obviously there is not mapping/processing for «non-stringable» keys,
and it is OK for top dict
but we still need EasyDict to transform nested dicts, etc.
So would be be great if:
Just dont set attributes if key is nonstringable (one line patch try/except, or something)
provide optional mapping functions as (EasyDict parameter) for such keys.
The text was updated successfully, but these errors were encountered:
belonesox
changed the title
Working with non-stringable keys — allow, but just dont set attributes.
Working with non-stringable keys — lets allow it, but just dont set attributes.
Oct 22, 2023
Lets consider an example:
Now we get exception:
Obviously there is not mapping/processing for «non-stringable» keys,
and it is OK for top dict
but we still need EasyDict to transform nested dicts, etc.
So would be be great if:
The text was updated successfully, but these errors were encountered: