Closed jgostick closed 2 hours ago
Another "normal" option would be dataclasses
We have decided to keep the Results object as the main return container, since they have a "clean" name space, meaning the autocomplete menu only contains the actual attributes, no additional cruft like methods and other meta info. For instance, named tuples have count
and index
by default and dicts have lots of methods like keys
etc. The clean namespace is better to just show only what is relevant.
The results object has attributes attached like
result.im_blah
, while adict
would beresult['im_blah']
. The dict is a bit more 'normal' but lacks other custom functionality, like printability.