diff --git a/client-cli/cli_lib/network.py b/client-cli/cli_lib/network.py index 624428f4..4523d499 100644 --- a/client-cli/cli_lib/network.py +++ b/client-cli/cli_lib/network.py @@ -42,10 +42,10 @@ def isValidIP(ipaddr): for block in ip4_blocks: # Check if number is digit, if not checked before calling this function if not block.isdigit(): - return False + return False tmp = int(block) if 0 > tmp > 255: - return False + return False return True return False diff --git a/client-cli/pvc.py b/client-cli/pvc.py index fb0860fd..0fbfe569 100755 --- a/client-cli/pvc.py +++ b/client-cli/pvc.py @@ -113,7 +113,7 @@ def get_config(store_data, cluster=None): def get_store(store_path): store_file = '{}/pvc-cli.json'.format(store_path) with open(store_file, 'r') as fh: - store_data = json.loads(fh.read()) + store_data = json.loads(fh.read()) return store_data def update_store(store_path, store_data): diff --git a/daemon-common/network.py b/daemon-common/network.py index cfc2c39a..fe5c74aa 100644 --- a/daemon-common/network.py +++ b/daemon-common/network.py @@ -214,10 +214,10 @@ def isValidIP(ipaddr): for block in ip4_blocks: # Check if number is digit, if not checked before calling this function if not block.isdigit(): - return False + return False tmp = int(block) if 0 > tmp > 255: - return False + return False return True return False diff --git a/node-daemon/pvcnoded/CephInstance.py b/node-daemon/pvcnoded/CephInstance.py index b6d92c91..d4461579 100644 --- a/node-daemon/pvcnoded/CephInstance.py +++ b/node-daemon/pvcnoded/CephInstance.py @@ -219,9 +219,9 @@ def remove_osd(zk_conn, logger, osd_id, osd_obj): osd_string = osd num_pgs = osd_string['num_pgs'] if num_pgs > 0: - time.sleep(5) + time.sleep(5) else: - raise + raise except Exception: break