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:
parent
fd0c65d176
commit
016f28250b
19 changed files with 124 additions and 58 deletions
|
@ -29,7 +29,7 @@ def pre_pip_dal_handler(
|
|||
Specifying modules' dependencies in the config or in my/config/repos is deprecated!
|
||||
Please install {' '.join(requires)} as PIP packages (see the corresponding README instructions).
|
||||
'''.strip(), stacklevel=2)
|
||||
except ModuleNotFoundError as ee:
|
||||
except ModuleNotFoundError:
|
||||
dal = None
|
||||
|
||||
if dal is None:
|
||||
|
@ -83,7 +83,9 @@ else:
|
|||
from typing import TypeVar, Callable
|
||||
Cl = TypeVar('Cl')
|
||||
R = TypeVar('R')
|
||||
|
||||
def cached_property(f: Callable[[Cl], R]) -> R:
|
||||
import functools
|
||||
return property(functools.lru_cache(maxsize=1)(f)) # type: ignore
|
||||
del Cl
|
||||
del R
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue