Skip to content

plugins.aea-dev-helpers.aea_dev_helpers.deploy_registry

Deploy all new packages to registry.

This module contains the logic originally in scripts/deploy_to_registry.py.

default_config_file_paths

def default_config_file_paths() -> Generator

Get (generator) the default config file paths.

unified_yaml_load

def unified_yaml_load(configuration_file: Path) -> Dict

Load YAML file, unified (both single- and multi-paged).

Arguments:

  • configuration_file: the configuration file path.

Returns:

the data.

get_public_id_from_yaml

def get_public_id_from_yaml(configuration_file: Path)

Get the public id from yaml.

Arguments:

  • configuration_file: the path to the config yaml

Returns:

public id

find_all_packages_ids

def find_all_packages_ids() -> Set[PackageId]

Find all packages ids.

check_correct_author

def check_correct_author(runner: CliRunner) -> None

Check whether the correct author is locally configured.

Arguments:

  • runner: the cli runner

push_package

def push_package(package_id, runner: CliRunner) -> None

Pushes a package (protocol/contract/connection/skill) to registry.

Specifically: - creates an empty agent project - adds the relevant package from local 'packages' dir (and its dependencies) - moves the relevant package out of vendor dir - pushes the relevant package to registry

Arguments:

  • package_id: the package id
  • runner: the cli runner

publish_agent

def publish_agent(package_id, runner: CliRunner) -> None

Publishes an agent to registry.

Specifically: - fetches an agent project from local 'packages' dir (and its dependencies) - publishes the agent project to registry

Arguments:

  • package_id: the package id
  • runner: the cli runner

Returns:

None

check_and_upload

def check_and_upload(package_id, runner: CliRunner) -> None

Check and upload.

Checks whether a package is missing from registry. If it is missing, uploads it.

Arguments:

  • package_id: the package id
  • runner: the cli runner

upload_new_packages

def upload_new_packages(runner: CliRunner,
                        all_package_ids: Set[PackageId]) -> None

Upload new packages.

Checks whether packages are missing from registry in the dependency order.

Arguments:

  • runner: the cli runner
  • all_package_ids: the set of all package ids to process.

main

def main() -> None

Run the deploy-to-registry workflow.

This is the main entry point intended to be called from a CLI wrapper.