Exception: KairosMcp::KairosChain::ChainStateError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/kairos_mcp/kairos_chain/chain.rb

Overview

Raised when the ledger's state on disk forbids appending, when a re-entrant append is attempted, or when the storage backend does not declare the contract of INV-G. Nothing has been written to the ledger; the lock file and its parent directory may have been created.

#state carries one of Chain::LOAD_STATES.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, state:) ⇒ ChainStateError

Returns a new instance of ChainStateError.



20
21
22
23
# File 'lib/kairos_mcp/kairos_chain/chain.rb', line 20

def initialize(message, state:)
  super(message)
  @state = state
end

Instance Attribute Details

#stateObject (readonly)

Returns the value of attribute state.



18
19
20
# File 'lib/kairos_mcp/kairos_chain/chain.rb', line 18

def state
  @state
end