Exception: LlmClient::ConnectionError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/llm_client/errors.rb

Overview

Custom error class for connection-related errors in LLM client.

This class inherits from the StandardError class and can be raised when there is an error in the connection to the LLM server.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, original_error) ⇒ ConnectionError

Initialize a new ConnectionError object with an error message and the original error.

Parameters:

message - A String representing the error message.
original_error - The original error object that caused the connection error.

Returns a new ConnectionError object.



19
20
21
22
# File 'lib/llm_client/errors.rb', line 19

def initialize(message, original_error)
  super(message)
  @original_error = original_error
end

Instance Attribute Details

#original_errorObject (readonly)

Returns the value of attribute original_error.



9
10
11
# File 'lib/llm_client/errors.rb', line 9

def original_error
  @original_error
end