general: initial flake8 checks (for now manual)

fix fairly uncontroversial stuff in my.core like
- line spacing, which isn't too annoying (e.g. unlike many inline whitespace checks that break vertical formatting)
- unused imports/variables
- too broad except
This commit is contained in:
Dima Gerasimov 2022-06-05 18:43:36 +01:00
parent fd0c65d176
commit b97a40c5ed
19 changed files with 124 additions and 58 deletions

View file

@ -1,6 +1,6 @@
# this file only keeps the most common & critical types/utility functions
from .common import PathIsh, Paths, Json
from .common import get_files
from .common import get_files, PathIsh, Paths
from .common import Json
from .common import LazyLogger
from .common import warn_if_empty
from .common import stat, Stats
@ -8,11 +8,32 @@ from .common import datetime_naive, datetime_aware
from .common import assert_never
from .cfg import make_config
from .util import __NOT_HPI_MODULE__
from .error import Res, unwrap
# just for brevity in modules
# todo not sure about these.. maybe best to rely on regular imports.. perhaps compare?
from dataclasses import dataclass
from pathlib import Path
__all__ = [
'get_files', 'PathIsh', 'Paths',
'Json',
'LazyLogger',
'warn_if_empty',
'stat', 'Stats',
'datetime_aware', 'datetime_naive',
'assert_never',
'make_config',
'__NOT_HPI_MODULE__',
'Res', 'unwrap',
'dataclass', 'Path',
]