Skip to content

packages.valory.skills.registration_abci.behaviours

This module contains the behaviours for the 'abci' skill.

RegistrationBaseBehaviour Objects

class RegistrationBaseBehaviour(BaseBehaviour)

Agent registration to the FSM App.

async_act

def async_act() -> Generator

Do the action.

Steps: - Build a registration transaction. - Send the transaction and wait for it to be mined. - Wait until ABCI application transitions to the next round. - Go to the next behaviour (set done event).

RegistrationStartupBehaviour Objects

class RegistrationStartupBehaviour(RegistrationBaseBehaviour)

Agent registration to the FSM App.

LogMessages Objects

class LogMessages(Enum)

Log messages used in RegistrationStartupBehaviour

__str__

def __str__() -> str

For ease of use in formatted string literals

registered_addresses

@property
def registered_addresses() -> Dict[str, Dict[str, Any]]

Agent addresses registered on-chain for the service

tendermint_parameter_url

@property
def tendermint_parameter_url() -> str

Tendermint URL for obtaining and updating parameters

is_correct_contract

def is_correct_contract() -> Generator[None, None, bool]

Contract deployment verification.

get_agent_instances

def get_agent_instances() -> Generator[None, None, Dict[str, Any]]

Get service info available on-chain

get_addresses

def get_addresses() -> Generator

Get addresses of agents registered for the service

get_tendermint_configuration

def get_tendermint_configuration() -> Generator[None, None, bool]

Make HTTP GET request to obtain agent's local Tendermint node parameters

request_tendermint_info

def request_tendermint_info() -> Generator[None, None, bool]

Request Tendermint info from other agents

format_genesis_data

def format_genesis_data(collected_agent_info: Dict[str, Any]) -> Dict[str, Any]

Format collected agent info for genesis update

request_update

def request_update() -> Generator[None, None, bool]

Make HTTP POST request to update agent's local Tendermint node

async_act

def async_act() -> Generator

Do the action.

Steps: 1. Collect personal Tendermint configuration 2. Make Service Registry contract call to retrieve addresses of the other agents registered on-chain for the service. 3. Request Tendermint configuration from registered agents. This is done over the Agent Communication Network using the p2p_libp2p_client connection. 4. Update Tendermint configuration via genesis.json with the information of the other validators (agents). 5. Restart Tendermint to establish the validator network.

RegistrationBehaviour Objects

class RegistrationBehaviour(RegistrationBaseBehaviour)

Agent registration to the FSM App.

AgentRegistrationRoundBehaviour Objects

class AgentRegistrationRoundBehaviour(AbstractRoundBehaviour)

This behaviour manages the consensus stages for the registration.

Back to top