Enable logging related ruff checks
... to extend the enforced format rules related to logging. Change-Id: Id6813930d045871c0482ab625776408dcf0bd1e1 Signed-off-by: Takashi Kajinami <kajinamit@oss.nttdata.com>
This commit is contained in:
@@ -65,7 +65,7 @@ disallow_any_generics = false
|
||||
line-length = 79
|
||||
|
||||
[tool.ruff.lint]
|
||||
select = ["C4", "E4", "E5", "E7", "E9", "F", "S", "U"]
|
||||
select = ["C4", "E4", "E5", "E7", "E9", "F", "G", "LOG", "S", "U"]
|
||||
ignore = [
|
||||
# we only use asserts for type narrowing
|
||||
"S101",
|
||||
|
||||
@@ -91,7 +91,7 @@ class ListPluginsDirective(rst.Directive):
|
||||
|
||||
def run(self) -> Sequence[nodes.Node]:
|
||||
namespace = ' '.join(self.content).strip()
|
||||
LOG.info(f'documenting plugins from {namespace!r}')
|
||||
LOG.info('documenting plugins from %r', namespace)
|
||||
overline_style = self.options.get('overline-style', '')
|
||||
underline_style = self.options.get('underline-style', '=')
|
||||
|
||||
@@ -100,7 +100,7 @@ class ListPluginsDirective(rst.Directive):
|
||||
ep: importlib.metadata.EntryPoint,
|
||||
err: BaseException,
|
||||
) -> None:
|
||||
LOG.warning(f'Failed to load {ep.module}: {err}')
|
||||
LOG.warning('Failed to load %s: %s', ep.module, err)
|
||||
|
||||
mgr: extension.ExtensionManager[Any]
|
||||
mgr = extension.ExtensionManager(
|
||||
|
||||
Reference in New Issue
Block a user