From 3069ed97314d524296e31fab39833d4af9cf1e19 Mon Sep 17 00:00:00 2001 From: Bartek Grzybowski Date: Tue, 24 Mar 2020 12:11:29 +0100 Subject: Fix unused varbiales pylint warnings Change-Id: I3f76a82d276c75f20453a9306b4f9964d90b5179 Issue-ID: INT-1482 Signed-off-by: Bartek Grzybowski --- .../src/producer/CustomKafkaProducer.py | 3 +-- .../sample-apps/sample-minio-save-model/build/save-model-to-minio.py | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) (limited to 'vnfs/DAaaS') diff --git a/vnfs/DAaaS/microservices/PythonApps/python-kafkaConsumer-inference-app/src/producer/CustomKafkaProducer.py b/vnfs/DAaaS/microservices/PythonApps/python-kafkaConsumer-inference-app/src/producer/CustomKafkaProducer.py index 43303761..6de868b7 100644 --- a/vnfs/DAaaS/microservices/PythonApps/python-kafkaConsumer-inference-app/src/producer/CustomKafkaProducer.py +++ b/vnfs/DAaaS/microservices/PythonApps/python-kafkaConsumer-inference-app/src/producer/CustomKafkaProducer.py @@ -23,8 +23,7 @@ class CustomKafkaProducer: ) self.producer.flush() - except Exception as e: - #print("Error during producing to kafka topic. Stacktrace is %s",e) + except Exception: logging.error("Error during producing to kafka topic.") traceback.print_exc() diff --git a/vnfs/DAaaS/sample-apps/sample-minio-save-model/build/save-model-to-minio.py b/vnfs/DAaaS/sample-apps/sample-minio-save-model/build/save-model-to-minio.py index c5198471..91207640 100755 --- a/vnfs/DAaaS/sample-apps/sample-minio-save-model/build/save-model-to-minio.py +++ b/vnfs/DAaaS/sample-apps/sample-minio-save-model/build/save-model-to-minio.py @@ -49,7 +49,7 @@ if __name__ == "__main__": found = False try: - client.stat_object(bucket_name, model); + client.stat_object(bucket_name, model) found = True except Exception as err: found = False @@ -62,5 +62,5 @@ if __name__ == "__main__": if not found: try: client.fput_object(bucket_name, model, filepath, metadata=metadata) - except expression as identifier: + except Exception as identifier: print(err) -- cgit 1.2.3-korg