22 lines
604 B
Python
22 lines
604 B
Python
# error_handler.py
|
|
|
|
import logging
|
|
|
|
def handle_general_error(e):
|
|
logging.error(f'An error occurred during the process: {e}')
|
|
# Add any additional error handling logic here
|
|
|
|
def handle_file_not_found_error(e):
|
|
logging.error(f"File not found error: {e}")
|
|
# Add any additional error handling logic here
|
|
|
|
def handle_value_error(e):
|
|
logging.error(f"Value error: {e}")
|
|
# Add any additional error handling logic here
|
|
|
|
def handle_error(error_message):
|
|
logging.error(f"Error: {error_message}")
|
|
|
|
class ClientError(Exception):
|
|
"""Custom exception class for client errors."""
|
|
pass |