fix: black

This commit is contained in:
egarette@silique.fr 2026-06-21 17:06:32 +02:00
parent a7752b5d0d
commit e0f8e55d40

View file

@ -1,7 +1,7 @@
""" """
Silique (https://www.silique.fr) Silique (https://www.silique.fr)
Copyright (C) 2022-2026 Copyright (C) 2022-2026
This program is free software: you can redistribute it and/or modify it This program is free software: you can redistribute it and/or modify it
under the terms of the GNU Lesser General Public License as published by the under the terms of the GNU Lesser General Public License as published by the
Free Software Foundation, either version 3 of the License, or (at your Free Software Foundation, either version 3 of the License, or (at your
@ -105,7 +105,7 @@ class RougailOutputJson:
for w in self.warnings: for w in self.warnings:
if isinstance(w, dict): if isinstance(w, dict):
msg, opt = next(iter(w.items())) msg, opt = next(iter(w.items()))
warnings.append(_('{0}: {1}').format(opt.path, msg)) warnings.append(_("{0}: {1}").format(opt.path, msg))
else: else:
warnings.append(w) warnings.append(w)
self.dico["_warnings"] = warnings self.dico["_warnings"] = warnings
@ -117,11 +117,11 @@ class RougailOutputJson:
for e in self.errors: for e in self.errors:
if isinstance(e, dict): if isinstance(e, dict):
msg, opt = next(iter(e.items())) msg, opt = next(iter(e.items()))
errors.append(_('{0}: {1}').format(opt.path, msg)) errors.append(_("{0}: {1}").format(opt.path, msg))
else: else:
errors.append(e) errors.append(e)
self.dico["_errors"] = errors self.dico["_errors"] = errors
#self.manage_warnings() # self.manage_warnings()
return False return False
def parse_family( def parse_family(
@ -139,7 +139,11 @@ class RougailOutputJson:
parent, parent,
) )
else: else:
if namespace is None and self.support_namespace and option.group_type() is groups.namespace: if (
namespace is None
and self.support_namespace
and option.group_type() is groups.namespace
):
subnamespace = option.name() subnamespace = option.name()
else: else:
subnamespace = namespace subnamespace = namespace