<p dir="ltr">Hum, timestamp and traceback_limit attributed of GroupedStats can also be removed, they are just of the same attribute of the Snapshot class and GroupedStats is created from Snapshot.group_by().</p>
<p dir="ltr">Le 27 oct. 2013 17:26, "Victor Stinner" <<a href="mailto:victor.stinner@gmail.com">victor.stinner@gmail.com</a>> a écrit :<br>
> * do you have a better suggestion for GroupedStats.stats attribute or<br>
> GroupedStats.statistics() method: "stats" and "statistics" are too<br>
> close</p>
<p dir="ltr">An option is to modify GroupedStats to inherit from dict, so GroupedStats.stats would be GroupedStats directly.</p>
<p dir="ltr">> * should GroupedStats.statistics() and GroupedStats.compare_to()<br>
> always sort the result to drop the sort=True parameter?</p>
<p dir="ltr">The result is a list which can be bigger than 100,000 items. The question is if it would inefficient to sort the list twice.</p>
<p dir="ltr">Another option is to replace sort parameter with a new sort_key parameter (callable), passed to list.sort as the ke parameter.</p>
<p dir="ltr">Victor</p>