From 6674a5e48601fbecc15e454f01eb13774d8731de Mon Sep 17 00:00:00 2001 From: Kelly A Date: Mon, 6 May 2024 09:30:04 -0400 Subject: [PATCH] =?UTF-8?q?=20=F0=9F=A7=B9remove=20unused=20variables?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Kelly A --- caikit/runtime/train.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/caikit/runtime/train.py b/caikit/runtime/train.py index f5fb32e7d..09508f84b 100644 --- a/caikit/runtime/train.py +++ b/caikit/runtime/train.py @@ -158,7 +158,7 @@ def main() -> int: for library in args.library or []: log.info("", "Importing library %s", library) importlib.import_module(library) - except Exception as e: + except Exception: message = "Unable to import module {}".format(library) log.warning( { @@ -193,7 +193,7 @@ def main() -> int: "Unable to find module {} to train", args.module, ) - except (ValueError, Exception) as e: + except (ValueError, Exception): message = "Unable to find module {} to train".format(args.module) log.warning( { @@ -262,7 +262,7 @@ def main() -> int: "stack_trace": traceback.format_exc(), } ) - except Exception as e: + except Exception: message = "Exception encountered when attempting to parse input parameters" log.warning( { @@ -292,7 +292,7 @@ def main() -> int: log.error(err) write_termination_log("Training finished unsuccessfully") return INTERNAL_ERROR_EXIT_CODE - except MemoryError as e: + except MemoryError: message = "OOM error during training" log.warning( { @@ -303,7 +303,7 @@ def main() -> int: ) write_termination_log(message) exit(INTERNAL_ERROR_EXIT_CODE) - except Exception as e: + except Exception: message = "Unhandled exception during training" log.warning( {