Skip to content

Commit

Permalink
Merge pull request #4 from valory-xyz/v0.4.1
Browse files Browse the repository at this point in the history
V0.4.1
  • Loading branch information
DavidMinarsch authored Aug 18, 2023
2 parents fbc2a69 + e5d7bdf commit 14b2aba
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 4 deletions.
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,18 @@ chmod +x run_service.sh
./run_service.sh
```

Once the command has completed, i.e. the service is running, you can see the live logs with:

```bash
docker logs trader_abci_0 --follow
```

To stop your agent, use:

```bash
cd trader; poetry run autonomy deploy stop --build-dir trader_service/abci_build; cd ..
```

## Observe your agents

1. Check out this handy app: https://predictions.oaksprout.repl.co/
Expand Down
8 changes: 4 additions & 4 deletions run_service.sh
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ fi
directory="trader"
# This is a tested version that works well.
# Feel free to replace this with a different version of the repo, but be careful as there might be breaking changes
service_version="v0.4.0"
service_version="v0.4.1"
service_repo=https://github.com/valory-xyz/$directory.git
if [ -d $directory ]
then
Expand Down Expand Up @@ -142,7 +142,7 @@ then
agent_balance=0
operator_balance=0
suggested_amount=50000000000000000
until [[ $agent_balance -gt $suggested_amount-1 && $operator_balance -gt $suggested_amount-1 ]]
until [[ $(python -c "print($agent_balance > ($suggested_amount-1))") == "True" && $(python -c "print($operator_balance > ($suggested_amount-1))") == "True" ]];
do
echo "Agent instance's balance: $agent_balance WEI."
echo "Operator's balance: $operator_balance WEI."
Expand Down Expand Up @@ -262,7 +262,7 @@ convert_hex_to_decimal() {
suggested_amount=500000000000000000
safe_balance_hex=$(get_balance)
safe_balance=$(convert_hex_to_decimal $safe_balance_hex)
while (( $safe_balance < $suggested_amount )); do
while [ "$(python -c "print($safe_balance < $suggested_amount)")" == "True" ]; do
echo "Safe's balance: $safe_balance WEI."
echo "The safe address needs to be funded."
echo "Please fund it with the amount you want to use for trading (at least 0.5 xDAI) to continue."
Expand Down Expand Up @@ -321,4 +321,4 @@ poetry run autonomy deploy build --n $n_agents -ltm
cd ..

# Run the deployment
poetry run autonomy deploy run --build-dir $directory
poetry run autonomy deploy run --build-dir $directory --detach

0 comments on commit 14b2aba

Please sign in to comment.