From: Michael Fritch Date: Thu, 28 Jan 2021 19:43:10 +0000 (-0700) Subject: mgr/cephadm: f-string is missing placeholders (F541) X-Git-Tag: v16.2.0~178^2~35 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=c421f8f3f13d26247d2d75927878b361614e9400;p=ceph.git mgr/cephadm: f-string is missing placeholders (F541) Signed-off-by: Michael Fritch (cherry picked from commit 22d6a1b7d8ce5530ef67f2ea8b1a9f9681dedf3a) --- diff --git a/src/pybind/mgr/cephadm/module.py b/src/pybind/mgr/cephadm/module.py index 8d4d86b89bec..9125905a675b 100644 --- a/src/pybind/mgr/cephadm/module.py +++ b/src/pybind/mgr/cephadm/module.py @@ -524,7 +524,7 @@ class CephadmOrchestrator(orchestrator.Orchestrator, MgrModule, # if _ANY_ osd that is currently in the queue appears to be empty, # start the removal process if int(osd.get('osd')) in self.to_remove_osds.as_osd_ids(): - self.log.debug(f"Found empty osd. Starting removal process") + self.log.debug('Found empty osd. Starting removal process') # if the osd that is now empty is also part of the removal queue # start the process self._kick_serve_loop() @@ -1341,7 +1341,7 @@ class CephadmOrchestrator(orchestrator.Orchestrator, MgrModule, :raises OrchestratorError: Hostname is invalid, host is already in maintenance """ if len(self.cache.get_hosts()) == 1: - raise OrchestratorError(f"Maintenance feature is not supported on single node clusters") + raise OrchestratorError("Maintenance feature is not supported on single node clusters") # if upgrade is active, deny if self.upgrade.upgrade_state: diff --git a/src/pybind/mgr/cephadm/serve.py b/src/pybind/mgr/cephadm/serve.py index 13ae1fec1f1b..a592397c48ed 100644 --- a/src/pybind/mgr/cephadm/serve.py +++ b/src/pybind/mgr/cephadm/serve.py @@ -329,7 +329,7 @@ class CephadmServe: # query OSDSpecs for host and generate/get the preview # There can be multiple previews for one host due to multiple OSDSpecs. previews.extend(self.mgr.osd_service.get_previews(search_host)) - self.log.debug(f"Loading OSDSpec previews to HostCache") + self.log.debug(f'Loading OSDSpec previews to HostCache for host <{search_host}>') self.mgr.cache.osdspec_previews[search_host] = previews # Unset global 'pending' flag for host self.mgr.cache.loading_osdspec_preview.remove(search_host) diff --git a/src/pybind/mgr/tox.ini b/src/pybind/mgr/tox.ini index dd66314258c9..972f8e82ecbe 100644 --- a/src/pybind/mgr/tox.ini +++ b/src/pybind/mgr/tox.ini @@ -13,7 +13,6 @@ max-line-length = 100 ignore = E501, F401, - F541, F632, F811, F821,