Commit 6da9ada3 authored by Samuel GAIST's avatar Samuel GAIST

[common] Update logger.warn to logger.warning

warn is obsolete.
parent 25e0d637
......@@ -264,7 +264,7 @@ class Selector(object):
with open(self.path, "rt") as f:
data = simplejson.load(f, object_pairs_hook=collections.OrderedDict)
except simplejson.JSONDecodeError:
logger.warn(
logger.warning(
"invalid state file at `%s' - removing and re-starting...", self.path
)
from beat.core.utils import safe_rmfile
......@@ -515,7 +515,7 @@ def display_local_list(prefix, asset_type):
if "description" in contents:
logger.extra(2 * " " + contents["description"])
except simplejson.JSONDecodeError:
logger.warn(2 * " " + "(!) invalid JSON file")
logger.warning(2 * " " + "(!) invalid JSON file")
if len(names) != 1:
logger.extra("%d %s found", len(names), TYPE_PLURAL[asset_type])
......@@ -694,7 +694,7 @@ def check_one(prefix, asset_type, name):
if not o.valid:
logger.info("%s/%s [invalid]", TYPE_PLURAL[asset_type], name)
for e in o.errors:
logger.warn(" * %s", e)
logger.warning(" * %s", e)
return 1
else:
......@@ -1394,7 +1394,7 @@ def push(
)
if not candidates:
logger.warn("No new candidates for upload were found")
logger.warning("No new candidates for upload were found")
return 0
# flush all final candidates
......@@ -1531,7 +1531,7 @@ def dot_diagram(prefix, asset_type, names, path, formats):
return 1
if not obj.valid:
logger.warn(
logger.warning(
"%s/%s is not valid - skipping it", TYPE_PLURAL[asset_type], name
)
continue
......@@ -1539,7 +1539,7 @@ def dot_diagram(prefix, asset_type, names, path, formats):
try:
diagram = obj.dot_diagram()
except Exception as e:
logger.warn(
logger.warning(
"%s/%s cannot be drawn: %s - skipping it",
TYPE_PLURAL[asset_type],
name,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment