Exception: Basecamp::NetworkError

Inherits:
Error
  • Object
show all
Defined in:
lib/basecamp/network_error.rb

Overview

Raised when there's a network error (connection, timeout, DNS).

Instance Method Summary collapse

Constructor Details

#initialize(message = "Network error", cause: nil) ⇒ NetworkError

Returns a new instance of NetworkError.



6
7
8
9
10
11
12
13
14
# File 'lib/basecamp/network_error.rb', line 6

def initialize(message = "Network error", cause: nil)
  super(
    code: ErrorCode::NETWORK,
    message: message,
    hint: cause&.message || "Check your network connection",
    retryable: true,
    cause: cause
  )
end