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
I am trying to use a custom dictionary class for all parsed dictionaries and I thought that I could do that using the translate callback to load/loads. Turns out, translate is only called for scalars and lists, but not for dictionaries (even though there is an elif kind == 'table': in process_value).
It would also be useful if there was a way to provide the dict class and have it done automatically (uiri/toml has such an option).
Thanks!
The text was updated successfully, but these errors were encountered:
Thanks! I guess translate is only called for inline tables. I'll have a look at the problem when I have a bit more time, and I'll probably also add object_hook and object_pairs_hook akin to what json.load has, so you can use object_pairs_hook=OrderedDict directly without going through translate.
I am trying to use a custom dictionary class for all parsed dictionaries and I thought that I could do that using the translate callback to load/loads. Turns out, translate is only called for scalars and lists, but not for dictionaries (even though there is an
elif kind == 'table':
in process_value).It would also be useful if there was a way to provide the dict class and have it done automatically (uiri/toml has such an option).
Thanks!
The text was updated successfully, but these errors were encountered: