Skip to content

aea.manager.project

This module contains the implementation of AEA agents project configuration.

_Base Objects

class _Base()

Base class to share some methods.

builder

 | @property
 | builder() -> AEABuilder

Get AEABuilder instance.

install_pypi_dependencies

 | install_pypi_dependencies() -> None

Install python dependencies for the project.

Project Objects

class Project(_Base)

Agent project representation.

__init__

 | __init__(public_id: PublicId, path: str) -> None

Init project with public_id and project's path.

build

 | build() -> None

Call all build entry points.

load

 | @classmethod
 | load(cls, working_dir: str, public_id: PublicId, is_local: bool = False, is_remote: bool = False, is_restore: bool = False, cli_verbosity: str = "INFO", registry_path: str = DEFAULT_REGISTRY_NAME, skip_consistency_check: bool = False, skip_aea_validation: bool = False) -> "Project"

Load project with given public_id to working_dir.

If local = False and remote = False, then the packages are fetched in mixed mode (i.e. first try from local registry, and then from remote registry in case of failure).

Arguments:

  • working_dir: the working directory
  • public_id: the public id
  • is_local: whether to fetch from local
  • is_remote: whether to fetch from remote
  • is_restore: whether to restore or not
  • cli_verbosity: the logging verbosity of the CLI
  • registry_path: the path to the registry locally
  • skip_consistency_check: consistency checks flag
  • skip_aea_validation: aea validation flag

Returns:

project

remove

 | remove() -> None

Remove project, do cleanup.

agent_config

 | @property
 | agent_config() -> AgentConfig

Get the agent configuration.

builder

 | @property
 | builder() -> AEABuilder

Get builder instance.

check

 | check() -> None

Check we can still construct an AEA from the project with builder.build.

AgentAlias Objects

class AgentAlias(_Base)

Agent alias representation.

__init__

 | __init__(project: Project, agent_name: str, data_dir: str, password: Optional[str] = None)

Init agent alias with project, config, name, agent, builder.

set_agent_config_from_data

 | set_agent_config_from_data(json_data: List[Dict]) -> None

Set agent config instance constructed from json data.

Arguments:

  • json_data: agent config json data

builder

 | @property
 | builder() -> AEABuilder

Get builder instance.

agent_config

 | @property
 | agent_config() -> AgentConfig

Get agent config.

remove_from_project

 | remove_from_project() -> None

Remove agent alias from project.

dict

 | @property
 | dict() -> Dict[str, Any]

Convert AgentAlias to dict.

config_json

 | @property
 | config_json() -> List[Dict]

Get agent config json data.

get_aea_instance

 | get_aea_instance() -> AEA

Build new aea instance.

issue_certificates

 | issue_certificates() -> None

Issue the certificates for this agent.

set_overrides

 | set_overrides(agent_overrides: Optional[Dict] = None, component_overrides: Optional[List[Dict]] = None) -> None

Set override for this agent alias's config.

agent_config_manager

 | @property
 | agent_config_manager() -> AgentConfigManager

Get agent configuration manager instance for the config.

get_overridables

 | get_overridables() -> Tuple[Dict, List[Dict]]

Get all overridables for this agent alias's config.

get_addresses

 | get_addresses() -> Dict[str, str]

Get addresses from private keys.

Returns:

dict with crypto id str as key and address str as value

get_connections_addresses

 | get_connections_addresses() -> Dict[str, str]

Get connections addresses from connections private keys.

Returns:

dict with crypto id str as key and address str as value