Exception: E2B::E2BError
- Inherits:
-
StandardError
- Object
- StandardError
- E2B::E2BError
- Defined in:
- lib/e2b/errors.rb
Overview
Base error class for all E2B SDK errors
Direct Known Subclasses
AuthenticationError, BuildError, CommandExitError, ConfigurationError, ConflictError, GitUpstreamError, InvalidArgumentError, NotEnoughSpaceError, NotFoundError, RateLimitError, SandboxStateError, TemplateError, TimeoutError
Instance Attribute Summary collapse
-
#headers ⇒ Hash
readonly
Response headers if available.
-
#status_code ⇒ Integer?
readonly
HTTP status code if available.
Instance Method Summary collapse
-
#initialize(message = nil, status_code: nil, headers: {}) ⇒ E2BError
constructor
A new instance of E2BError.
Constructor Details
#initialize(message = nil, status_code: nil, headers: {}) ⇒ E2BError
Returns a new instance of E2BError.
14 15 16 17 18 |
# File 'lib/e2b/errors.rb', line 14 def initialize( = nil, status_code: nil, headers: {}) @status_code = status_code @headers = headers || {} super() end |
Instance Attribute Details
#headers ⇒ Hash (readonly)
Response headers if available
8 9 10 |
# File 'lib/e2b/errors.rb', line 8 def headers @headers end |
#status_code ⇒ Integer? (readonly)
HTTP status code if available
8 9 10 |
# File 'lib/e2b/errors.rb', line 8 def status_code @status_code end |