From 049b7a5a2b13a69448937aba275ec2f35407b95e Mon Sep 17 00:00:00 2001 From: Alejandro Sirgo Rica Date: Mon, 18 Mar 2024 20:30:27 +0100 Subject: src: make exception messages more contextual and explicit Provide more information in exception messages as those are the source of the logging messages. Add information about paths, files or configuration related to the operation associated to the exception. --- src/ogRest.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/ogRest.py') diff --git a/src/ogRest.py b/src/ogRest.py index 47767b6..c7bdcdb 100644 --- a/src/ogRest.py +++ b/src/ogRest.py @@ -263,7 +263,7 @@ class ogRest(): from src.windows.ogOperations import OgWindowsOperations self.operations = OgWindowsOperations() else: - raise ValueError('Mode not supported.') + raise ValueError(f'Ogrest mode \'{self.mode}\'not supported') def send_internal_server_error(self, client, exc=None): if isinstance(exc, AssertionError): -- cgit v1.2.3-18-g5258