core.common: move stats-related stuff to my.core.stats and add more thorough tests/docs

deprecate core.common.stat and core.common.Stats with backwards compatibility
This commit is contained in:
Dima Gerasimov 2024-08-15 17:51:46 +03:00
parent 1f8c719e6d
commit 242e31b05c
14 changed files with 343 additions and 246 deletions

View file

@ -9,7 +9,7 @@ from pathlib import Path
from datetime import timedelta
from typing import Sequence, Iterable
from my.core import get_files, make_logger
from my.core import get_files, make_logger, stat, Stats
from my.core.cachew import mcachew
from my.core.error import Res, split_errors
@ -47,7 +47,6 @@ def dataframe() -> DataFrameT:
return as_dataframe(entries())
from .core import stat, Stats
def stats() -> Stats:
return {
**stat(groups),