moonraker: rename deprecated "logging.warn"
Python uses "logging.warning" to log warning level methods. Signed-off-by: Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
parent
dc4da6087f
commit
60d6c748ef
|
@ -328,7 +328,7 @@ class CommandHelper:
|
|||
self.server = config.get_server()
|
||||
self.debug_enabled = config.getboolean('enable_repo_debug', False)
|
||||
if self.debug_enabled:
|
||||
logging.warn("UPDATE MANAGER: REPO DEBUG ENABLED")
|
||||
logging.warning("UPDATE MANAGER: REPO DEBUG ENABLED")
|
||||
shell_cmd: SCMDComp = self.server.lookup_component('shell_command')
|
||||
self.scmd_error = shell_cmd.error
|
||||
self.build_shell_command = shell_cmd.build_shell_command
|
||||
|
|
|
@ -161,7 +161,7 @@ class Server:
|
|||
def add_warning(self, warning: str, log: bool = True) -> None:
|
||||
self.warnings.append(warning)
|
||||
if log:
|
||||
logging.warn(warning)
|
||||
logging.warning(warning)
|
||||
|
||||
# ***** Component Management *****
|
||||
def _load_components(self, config: confighelper.ConfigHelper) -> None:
|
||||
|
|
Loading…
Reference in New Issue