Skip to content

Commit

Permalink
key args
Browse files Browse the repository at this point in the history
  • Loading branch information
pcrespov committed Oct 15, 2024
1 parent 573c17b commit cf4b04b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/service-library/src/servicelib/logging_errors.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@

def create_troubleshotting_log_message(
error_user_msg: str,
*,
error: BaseException,
error_code: ErrorCodeStr,
error_context: dict[str, Any] | None = None,
Expand All @@ -20,7 +21,7 @@ def create_troubleshotting_log_message(
"""Create a formatted message for _logger.exception(...)
Arguments:
message_to_user -- A user-friendly message to be displayed on the front-end explaining the issue in simple terms.
error_user_msg -- A user-friendly message to be displayed on the front-end explaining the issue in simple terms.
error -- the instance of the handled exception
error_code -- A unique error code (e.g., OEC or osparc-specific) to identify the type or source of the error for easier tracking.
error_context -- Additional context surrounding the exception, such as environment variables or function-specific data. This can be derived from exc.error_context() (relevant when using the OsparcErrorMixin)
Expand All @@ -47,6 +48,7 @@ class LogKwargs(TypedDict):

def create_troubleshotting_log_kwargs(
error_user_msg: str,
*,
error: BaseException,
error_context: dict[str, Any] | None = None,
tip: str | None = None,
Expand Down

0 comments on commit cf4b04b

Please sign in to comment.