Skip to content

Commit

Permalink
relayer: only configure penumbra chains
Browse files Browse the repository at this point in the history
We encountered a long (~20s) timeout on all `rly` commands, and traced
it to a context timeout on a bad URL for the bablyon testchain. We're
still focusing on preview <-> devnet functionality, so let's exclude the
external testnet chains from relayer configuration until we're ready.

Also includes some documentation updates so it's a bit easier to
understand how test the relayer interactively. Eventually we'll want all
this logic bottled up in integration tests, e.g. `interchaintest`, but
still working toward that goal.

Refs #2612.
  • Loading branch information
conorsch committed Jul 7, 2023
1 parent 15df6a0 commit 155b0be
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 3 deletions.
15 changes: 15 additions & 0 deletions deployments/relayer/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,21 @@ Given the rapid pace of development, it's possible that proto definitions
are out of sync between testnet & preview, in which case there may be errors.
To debug, consider running a local devnet and linking it with preview.

## Verifying IBC functionality between chains

There are three key stages to working IBC: clients, channels, and connections.
Use the commands below to evaluate whether each step is correctly configured:

```
pcli -n http://localhost:8080 q ibc client 07-tendermint-0
pcli -n http://localhost:8080 q ibc channel transfer channel-0
pcli -n http://localhost:8080 q ibc connection connection-0
```

Remember to check the same on the corresponding counterparty chain, e.g. testnet-preview.
The `client` values may not be the same between chains, so try incrementing the values
until no results are found as a surrogate for querying via pcli.

## Updating proto definitions in relayer
Sometimes the protos between preview & testnet get out of sync. When this happens,
we must submit a PR upstream to the relayer repo. See [example here](https://github.com/cosmos/relayer/pull/1170),
Expand Down
8 changes: 8 additions & 0 deletions deployments/relayer/build-path
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,11 @@ done < <(rly paths list --json | jq 'keys | join ("\n")' -r | sort -r)

visible_log "Finished! No errors encountered setting up link. Available paths:"
rly paths list

visible_log "These commands should all yield results:"

cat <<EOF
* pcli -n http://localhost:8080 q ibc client 07-tendermint-0
* pcli -n http://localhost:8080 q ibc channel transfer channel-0
* pcli -n http://localhost:8080 q ibc connection connection-0
EOF
2 changes: 1 addition & 1 deletion deployments/relayer/configs/babylon-testnet.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"value": {
"key": "default",
"chain-id": "bbn-test1",
"rpc-addr": "http://rpc.testnet.babylonchain.io:26657",
"rpc-addr": "https://rpc.testnet.babylonchain.io:443",
"account-prefix": "bbn",
"keyring-backend": "test",
"gas-adjustment": 1.0,
Expand Down
2 changes: 1 addition & 1 deletion deployments/relayer/configs/penumbra-preview.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"type": "penumbra",
"value": {
"key": "default",
"chain-id": "penumbra-testnet-amalthe-7ceb20c6",
"chain-id": "penumbra-testnet-callisto-7c9d59d6",
"rpc-addr": "https://rpc.testnet-preview.penumbra.zone:443",
"account-prefix": "penumbrav2t",
"keyring-backend": "test",
Expand Down
3 changes: 2 additions & 1 deletion deployments/relayer/configure-relayer
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@ rm -rf ~/.relayer
rly config init --memo "Automatic IBC for Penumbra, via relayer"

>&2 echo "Adding chain specs to relayer config..."
rly chains add-dir configs/
find ./configs/ -type f -iname 'penumbra*.json' -exec \
rly chains add -f {} \;

# Ideally we wouldn't need to bother with generating keys for the relayer paths,
# because Penumbra hasn't implemented fees yet, so there's no need for a wallet to pay out of.
Expand Down

0 comments on commit 155b0be

Please sign in to comment.