Skip to content

Commit

Permalink
Merge pull request #2330 from fetchai/feature/v0.11.0
Browse files Browse the repository at this point in the history
[AEA-1316] Feature/v0.11.0
  • Loading branch information
DavidMinarsch authored Mar 4, 2021
2 parents 29aef9f + 8d62604 commit 6cced80
Show file tree
Hide file tree
Showing 347 changed files with 3,483 additions and 2,404 deletions.
2 changes: 2 additions & 0 deletions .spelling
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,8 @@ Yoti
PowerShell
deregisters
plugin
Fetch.AI
AEALite
- docs/language-agnostic-definition.md
fetchai
protocol_id
Expand Down
25 changes: 25 additions & 0 deletions HISTORY.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,30 @@
# Release History

## 0.11.0 (2020-03-04)

- Adds slots usage in frequently used framework objects, including `Dialogue`
- Fixes a bug in `aea upgrade` command where eject prompt was not offered
- Refactors skill component configurations to allow for skill components (`Handler`, `Behaviour`, `Model`) to be placed anywhere in a skill
- Extends skill component configuration to specify optional `file_path` field
- Extracts all ledger specific functionality in plugins
- Improves error logging in http server connection
- Updates `Development - Use case` documentation
- Adds restart support to `p2p_libp2p` connection on read/write failure
- Adds validation of default routing and default connection configuration
- Refactors and significantly simplifies routing between components
- Limits usage of `EnvelopeContext`
- Adds support for new CosmWasm message format in ledger plugins
- Adds project loading checks and optional auto removal in `MultiAgentManager`
- Adds support for reuse of threaded `Multiplexer`
- Fixes bug in TAC which caused agents to make suboptimal trades
- Adds support to specify dependencies on `aea-config.yaml` level
- Improves release scripts
- Adds lightweight Golang AEALite library
- Adds support for skill-to-skill messages
- Removes CLI GUI
- Multiple docs updates based on user feedback
- Multiple additional tests and test stability fixes

## 0.10.1 (2020-02-21)

- Changes default URL of `soef` connection to https
Expand Down
4 changes: 2 additions & 2 deletions SECURITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ The following table shows which versions of `aea` are currently being supported

| Version | Supported |
| --------- | ------------------ |
| `0.10.x` | :white_check_mark: |
| `< 0.10.0` | :x: |
| `0.11.x` | :white_check_mark: |
| `< 0.11.0` | :x: |

## Reporting a Vulnerability

Expand Down
2 changes: 1 addition & 1 deletion aea/__version__.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
__title__ = "aea"
__description__ = "Autonomous Economic Agent framework"
__url__ = "https://github.com/fetchai/agents-aea.git"
__version__ = "0.10.1"
__version__ = "0.11.0"
__author__ = "Fetch.AI Limited"
__license__ = "Apache-2.0"
__copyright__ = "2019 Fetch.AI Limited"
2 changes: 1 addition & 1 deletion aea/connections/scaffold/connection.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ type: connection
description: The scaffold connection provides a scaffold for a connection to be implemented
by the developer.
license: Apache-2.0
aea_version: '>=0.10.0, <0.11.0'
aea_version: '>=0.11.0, <0.12.0'
fingerprint:
__init__.py: QmZvYZ5ECcWwqiNGh8qNTg735wu51HqaLxTSifUxkQ4KGj
connection.py: QmRQASdBp3e7d7oDoEnxHcVfM7wvVQFWUE44DXbqpc3kDU
Expand Down
2 changes: 1 addition & 1 deletion aea/contracts/scaffold/contract.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version: 0.1.0
type: contract
description: The scaffold contract scaffolds a contract to be implemented by the developer.
license: Apache-2.0
aea_version: '>=0.10.0, <0.11.0'
aea_version: '>=0.11.0, <0.12.0'
fingerprint:
__init__.py: QmPBwWhEg3wcH1q9612srZYAYdANVdWLDFWKs7TviZmVj6
contract.py: QmbaG1cJbzb1oNAce78n8UuLKqquHFLvHKKBfHL5F5Ci7G
Expand Down
2 changes: 1 addition & 1 deletion aea/protocols/scaffold/protocol.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version: 0.1.0
type: protocol
description: The scaffold protocol scaffolds a protocol to be implemented by the developer.
license: Apache-2.0
aea_version: '>=0.10.0, <0.11.0'
aea_version: '>=0.11.0, <0.12.0'
protocol_specification_id: fetchai/scaffold:0.1.0
fingerprint:
__init__.py: Qmc9Ln8THrWmwou4nr3Acag7vcZ1fv8v5oRSkCWtv1aH6t
Expand Down
2 changes: 1 addition & 1 deletion aea/skills/scaffold/skill.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version: 0.1.0
type: skill
description: The scaffold skill is a scaffold for your own skill implementation.
license: Apache-2.0
aea_version: '>=0.10.0, <0.11.0'
aea_version: '>=0.11.0, <0.12.0'
fingerprint:
__init__.py: QmYRssFqDqb3uWDvfoXy93avisjKRx2yf9SbAQXnkRj1QB
behaviours.py: QmNgDDAmBzWBeBF7e5gUCny38kdqVVfpvHGaAZVZcMtm9Q
Expand Down
2 changes: 1 addition & 1 deletion benchmark/run_from_branch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ pip install pipenv
# this is to install benchmark dependencies
pipenv install --dev --skip-lock
# this is to install the AEA in the Pipenv virtual env
pipenv run pip install --upgrade aea[all]=="0.10.1"
pipenv run pip install --upgrade aea[all]=="0.11.0"

chmod +x benchmark/checks/run_benchmark.sh
echo "Start the experiments."
Expand Down
2 changes: 1 addition & 1 deletion deploy-image/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ENV PYTHONPATH "$PYTHONPATH:/usr/lib/python3.7/site-packages"
RUN apk add --no-cache go

RUN pip install --upgrade pip
RUN pip install --upgrade --force-reinstall aea[all]==0.10.1
RUN pip install --upgrade --force-reinstall aea[all]==0.11.0

# COPY ./packages /home/packages # enable to add packages dir
WORKDIR home
Expand Down
2 changes: 1 addition & 1 deletion deploy-image/docker-env.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash

# Swap the following lines if you want to work with 'latest'
DOCKER_IMAGE_TAG=fetchai/aea-deploy:0.10.1
DOCKER_IMAGE_TAG=fetchai/aea-deploy:0.11.0
# DOCKER_IMAGE_TAG=fetchai/aea-deploy:latest

DOCKER_BUILD_CONTEXT_DIR=..
Expand Down
2 changes: 1 addition & 1 deletion develop-image/docker-env.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash

# Swap the following lines if you want to work with 'latest'
DOCKER_IMAGE_TAG=fetchai/aea-develop:0.10.1
DOCKER_IMAGE_TAG=fetchai/aea-develop:0.11.0
# DOCKER_IMAGE_TAG=aea-develop:latest

DOCKER_BUILD_CONTEXT_DIR=..
Expand Down
76 changes: 76 additions & 0 deletions docs/api/agent_loop.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,23 @@ Get agent.

Get current main loop state.

<a name="aea.agent_loop.BaseAgentLoop.wait_state"></a>
#### wait`_`state

```python
| async wait_state(state_or_states: Union[Any, Sequence[Any]]) -> Tuple[Any, Any]
```

Wait state to be set.

**Arguments**:

- `state_or_states`: state or list of states.

**Returns**:

tuple of previous state and new state.

<a name="aea.agent_loop.BaseAgentLoop.is_running"></a>
#### is`_`running

Expand Down Expand Up @@ -92,6 +109,36 @@ Set event loop and all event loopp related objects.

Run agent loop.

<a name="aea.agent_loop.BaseAgentLoop.send_to_skill"></a>
#### send`_`to`_`skill

```python
| @abstractmethod
| send_to_skill(message_or_envelope: Union[Message, Envelope], context: Optional[EnvelopeContext] = None) -> None
```

Send message or envelope to another skill.

**Arguments**:

- `message_or_envelope`: envelope to send to another skill.
if message passed it will be wrapped into envelope with optional envelope context.

**Returns**:

None

<a name="aea.agent_loop.BaseAgentLoop.skill2skill_queue"></a>
#### skill2skill`_`queue

```python
| @property
| @abstractmethod
| skill2skill_queue() -> Queue
```

Get skill to skill message queue.

<a name="aea.agent_loop.AsyncAgentLoop"></a>
## AsyncAgentLoop Objects

Expand All @@ -114,4 +161,33 @@ Init agent loop.

- `agent`: AEA instance
- `loop`: asyncio loop to use. optional
- `threaded`: is a new thread to be started for the agent loop

<a name="aea.agent_loop.AsyncAgentLoop.skill2skill_queue"></a>
#### skill2skill`_`queue

```python
| @property
| skill2skill_queue() -> Queue
```

Get skill to skill message queue.

<a name="aea.agent_loop.AsyncAgentLoop.send_to_skill"></a>
#### send`_`to`_`skill

```python
| send_to_skill(message_or_envelope: Union[Message, Envelope], context: Optional[EnvelopeContext] = None) -> None
```

Send message or envelope to another skill.

**Arguments**:

- `message_or_envelope`: envelope to send to another skill.
if message passed it will be wrapped into envelope with optional envelope context.

**Returns**:

None

44 changes: 31 additions & 13 deletions docs/api/configurations/base.md
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,17 @@ Get the 'aea_version' attribute.

Set the 'aea_version' attribute.

<a name="aea.configurations.base.PackageConfiguration.check_aea_version"></a>
#### check`_`aea`_`version

```python
| check_aea_version() -> None
```

Check that the AEA version matches the specifier set.

:raises ValueError if the version of the aea framework falls within a specifier.

<a name="aea.configurations.base.PackageConfiguration.directory"></a>
#### directory

Expand Down Expand Up @@ -415,17 +426,6 @@ Check that the fingerprint are correct against a directory path.
- the argument is not a valid package directory
- the fingerprints do not match.

<a name="aea.configurations.base.ComponentConfiguration.check_aea_version"></a>
#### check`_`aea`_`version

```python
| check_aea_version() -> None
```

Check that the AEA version matches the specifier set.

:raises ValueError if the version of the aea framework falls within a specifier.

<a name="aea.configurations.base.ComponentConfiguration.check_public_id_consistency"></a>
#### check`_`public`_`id`_`consistency

Expand Down Expand Up @@ -528,7 +528,7 @@ This class represent a skill component configuration.
#### `__`init`__`

```python
| __init__(class_name: str, **args: Any) -> None
| __init__(class_name: str, file_path: Optional[str] = None, **args: Any) -> None
```

Initialize a skill component configuration.
Expand Down Expand Up @@ -629,7 +629,7 @@ Class to represent the agent configuration file.
#### `__`init`__`

```python
| __init__(agent_name: SimpleIdOrStr, author: SimpleIdOrStr, version: str = "", license_: str = "", aea_version: str = "", fingerprint: Optional[Dict[str, str]] = None, fingerprint_ignore_patterns: Optional[Sequence[str]] = None, build_entrypoint: Optional[str] = None, registry_path: str = DEFAULT_REGISTRY_NAME, description: str = "", logging_config: Optional[Dict] = None, period: Optional[float] = None, execution_timeout: Optional[float] = None, max_reactions: Optional[int] = None, error_handler: Optional[Dict] = None, decision_maker_handler: Optional[Dict] = None, skill_exception_policy: Optional[str] = None, connection_exception_policy: Optional[str] = None, default_ledger: Optional[str] = None, currency_denominations: Optional[Dict[str, str]] = None, default_connection: Optional[str] = None, default_routing: Optional[Dict[str, str]] = None, loop_mode: Optional[str] = None, runtime_mode: Optional[str] = None, storage_uri: Optional[str] = None, data_dir: Optional[str] = None, component_configurations: Optional[Dict[ComponentId, Dict]] = None) -> None
| __init__(agent_name: SimpleIdOrStr, author: SimpleIdOrStr, version: str = "", license_: str = "", aea_version: str = "", fingerprint: Optional[Dict[str, str]] = None, fingerprint_ignore_patterns: Optional[Sequence[str]] = None, build_entrypoint: Optional[str] = None, registry_path: str = DEFAULT_REGISTRY_NAME, description: str = "", logging_config: Optional[Dict] = None, period: Optional[float] = None, execution_timeout: Optional[float] = None, max_reactions: Optional[int] = None, error_handler: Optional[Dict] = None, decision_maker_handler: Optional[Dict] = None, skill_exception_policy: Optional[str] = None, connection_exception_policy: Optional[str] = None, default_ledger: Optional[str] = None, currency_denominations: Optional[Dict[str, str]] = None, default_connection: Optional[str] = None, default_routing: Optional[Dict[str, str]] = None, loop_mode: Optional[str] = None, runtime_mode: Optional[str] = None, storage_uri: Optional[str] = None, data_dir: Optional[str] = None, component_configurations: Optional[Dict[ComponentId, Dict]] = None, dependencies: Optional[Dependencies] = None) -> None
```

Instantiate the agent configuration object.
Expand Down Expand Up @@ -867,3 +867,21 @@ Initialize a protocol configuration object.

Return the JSON representation.

<a name="aea.configurations.base.AEAVersionError"></a>
## AEAVersionError Objects

```python
class AEAVersionError(ValueError)
```

Special Exception for version error.

<a name="aea.configurations.base.AEAVersionError.__init__"></a>
#### `__`init`__`

```python
| __init__(package_id: PublicId, aea_version_specifiers: SpecifierSet) -> None
```

Init exception.

24 changes: 21 additions & 3 deletions docs/api/configurations/data_types.md
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,24 @@ the public id object.

- `ValueError`: if the string in input is not well formatted.

<a name="aea.configurations.data_types.PublicId.try_from_str"></a>
#### try`_`from`_`str

```python
| @classmethod
| try_from_str(cls, public_id_string: str) -> Optional["PublicId"]
```

Safely try to get public id from string.

**Arguments**:

- `public_id_string`: the public id in string format.

**Returns**:

the public id object or None

<a name="aea.configurations.data_types.PublicId.from_uri_path"></a>
#### from`_`uri`_`path

Expand Down Expand Up @@ -559,7 +577,7 @@ Get the package identifier without the version.
| from_uri_path(cls, package_id_uri_path: str) -> "PackageId"
```

Initialize the public id from the string.
Initialize the package id from the string.

>>> str(PackageId.from_uri_path("skill/author/package_name/0.1.0"))
'(skill, author/package_name:0.1.0)'
Expand All @@ -572,11 +590,11 @@ ValueError: Input 'very/bad/formatted:input' is not well formatted.

**Arguments**:

- `public_id_uri_path`: the public id in uri path string format.
- `package_id_uri_path`: the package id in uri path string format.

**Returns**:

the public id object.
the package id object.

**Raises**:

Expand Down
20 changes: 19 additions & 1 deletion docs/api/context/base.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Provide read access to relevant objects of the agent for the skills.
#### `__`init`__`

```python
| __init__(identity: Identity, connection_status: MultiplexerStatus, outbox: OutBox, decision_maker_message_queue: Queue, decision_maker_handler_context: SimpleNamespace, task_manager: TaskManager, default_ledger_id: str, currency_denominations: Dict[str, str], default_connection: Optional[PublicId], default_routing: Dict[PublicId, PublicId], search_service_address: Address, decision_maker_address: Address, data_dir: str, storage_callable: Callable[[], Optional[Storage]] = lambda: None, **kwargs: Any) -> None
| __init__(identity: Identity, connection_status: MultiplexerStatus, outbox: OutBox, decision_maker_message_queue: Queue, decision_maker_handler_context: SimpleNamespace, task_manager: TaskManager, default_ledger_id: str, currency_denominations: Dict[str, str], default_connection: Optional[PublicId], default_routing: Dict[PublicId, PublicId], search_service_address: Address, decision_maker_address: Address, data_dir: str, storage_callable: Callable[[], Optional[Storage]] = lambda: None, send_to_skill: Optional[Callable] = None, **kwargs: Any) -> None
```

Initialize an agent context.
Expand All @@ -39,6 +39,24 @@ Initialize an agent context.
- `storage_callable`: function that returns optional storage attached to agent.
- `kwargs`: keyword arguments to be attached in the agent context namespace.

<a name="aea.context.base.AgentContext.send_to_skill"></a>
#### send`_`to`_`skill

```python
| send_to_skill(message_or_envelope: Union[Message, Envelope], context: Optional[EnvelopeContext] = None) -> None
```

Send message or envelope to another skill.

**Arguments**:

- `message_or_envelope`: envelope to send to another skill.
if message passed it will be wrapped into envelope with optional envelope context.

**Returns**:

None

<a name="aea.context.base.AgentContext.storage"></a>
#### storage

Expand Down
Loading

0 comments on commit 6cced80

Please sign in to comment.