ruff: enable B warnings (mainly suppressed exceptions and unused variables)
This commit is contained in:
parent
f563dee215
commit
8b1ec35286
30 changed files with 83 additions and 67 deletions
|
@ -2,7 +2,6 @@ from .internal import assert_subpackage; assert_subpackage(__name__)
|
|||
|
||||
import logging
|
||||
import sys
|
||||
import warnings
|
||||
from contextlib import contextmanager
|
||||
from pathlib import Path
|
||||
from typing import (
|
||||
|
@ -20,6 +19,9 @@ from typing import (
|
|||
|
||||
import appdirs # type: ignore[import-untyped]
|
||||
|
||||
from . import warnings
|
||||
|
||||
|
||||
PathIsh = Union[str, Path] # avoid circular import from .common
|
||||
|
||||
|
||||
|
@ -116,7 +118,7 @@ def _mcachew_impl(cache_path=_cache_path_dflt, **kwargs):
|
|||
try:
|
||||
import cachew
|
||||
except ModuleNotFoundError:
|
||||
warnings.warn('cachew library not found. You might want to install it to speed things up. See https://github.com/karlicoss/cachew')
|
||||
warnings.high('cachew library not found. You might want to install it to speed things up. See https://github.com/karlicoss/cachew')
|
||||
return lambda orig_func: orig_func
|
||||
else:
|
||||
kwargs['cache_path'] = cache_path
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue