diff --git a/binarycpython/utils/functions.py b/binarycpython/utils/functions.py index 2fb54fc6986480fb90dd6d6c9b1d8cea20f144d0..18371010a825d8a4e904a6d2533e0c4ce8891ff7 100644 --- a/binarycpython/utils/functions.py +++ b/binarycpython/utils/functions.py @@ -9,11 +9,6 @@ from collections import defaultdict import numpy as np import binary_c_python_api -# from binarycpython.utils.custom_logging_functions import ( -# create_and_load_logging_function, -# ) - - def remove_file(file, verbose=0): """ Function to remove files but with verbosity diff --git a/binarycpython/utils/run_system_wrapper.py b/binarycpython/utils/run_system_wrapper.py index b6f471baf8ad867dd33774213843a03f59e945d9..7166b031811c181f4da685f5b16343336a458224 100644 --- a/binarycpython/utils/run_system_wrapper.py +++ b/binarycpython/utils/run_system_wrapper.py @@ -32,12 +32,16 @@ def run_system(**kwargs): Todo: * Expand functionality. - + * Notify user when an unknown keyword is passed """ # Load available arg keywords available_binary_c_arg_keywords = get_arg_keys() + other_keywords = ['custom_logging_code', 'log_filename', 'parse_function'] + + + # Set default values func_memaddr = -1 write_logfile = 0 @@ -50,6 +54,12 @@ def run_system(**kwargs): if key in available_binary_c_arg_keywords: binary_c_args[key] = kwargs[key] + # Notify user when this key wont be used + else: + if not key in other_keywords: + print("The following keyword was not recognized and wont be used:\n\t{}".format(key)) + + # Check if custom logging is required if "custom_logging_code" in kwargs: func_memaddr, shared_lib_filename = create_and_load_logging_function(