diff --git a/litellm/litellm_core_utils/litellm_logging.py b/litellm/litellm_core_utils/litellm_logging.py index 25d12d3cb1b..9a2cea3fa2c 100644 --- a/litellm/litellm_core_utils/litellm_logging.py +++ b/litellm/litellm_core_utils/litellm_logging.py @@ -978,8 +978,10 @@ class Logging(LiteLLMLoggingBaseClass): try: # [Non-blocking Extra Debug Information in metadata] if turn_off_message_logging is True: - _metadata["raw_request"] = "redacted by litellm. \ + _metadata["raw_request"] = ( + "redacted by litellm. \ 'litellm.turn_off_message_logging=True'" + ) else: curl_command = self._get_request_curl_command( api_base=additional_args.get("api_base", ""), @@ -1013,8 +1015,12 @@ class Logging(LiteLLMLoggingBaseClass): ] = RawRequestTypedDict( error=str(e), ) - _metadata["raw_request"] = "Unable to Log \ - raw request: {}".format(str(e)) + _metadata["raw_request"] = ( + "Unable to Log \ + raw request: {}".format( + str(e) + ) + ) if getattr(self, "logger_fn", None) and callable(self.logger_fn): try: self.logger_fn(