Skip to content

Commit

Permalink
fix(ci): iota-rosetta validation (#4496)
Browse files Browse the repository at this point in the history
* refactor(ci): skip on condition genesis creation for rosetta setup

Since there is no cleanup in the setup and we use a self-hosted runner,
the genesis persists between runs.

* fix(iota-rosetta): disable historical balance checks

We don't support account-balances lookups at specific heights (at least
in a trivial matter). So the following applies

```
$ ./bin/rosetta-cli check:data --help
By default, account balances are looked up at specific heights (instead of
only at the current block). If your node does not support this functionality
set historical balance disabled to true. This will make reconciliation much
less efficient but it will still work.
```

* fixup! refactor(ci): skip on condition genesis creation for rosetta setup

* fixup! fixup! refactor(ci): skip on condition genesis creation for rosetta setup
  • Loading branch information
kodemartin authored Dec 13, 2024
1 parent 857d515 commit 599ad39
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
9 changes: 4 additions & 5 deletions .github/scripts/rosetta/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,11 @@ echo "Install binaries"
cargo install --locked --bin iota --path crates/iota
cargo install --locked --bin iota-rosetta --path crates/iota-rosetta

echo "create dedicated config dir for IOTA genesis"
CONFIG_DIR="~/.iota/rosetta_config"
mkdir -p $CONFIG_DIR

echo "run IOTA genesis"
iota genesis -f --working-dir $CONFIG_DIR
CONFIG_DIR=~/.iota/iota_config
if ! [ -d "$CONFIG_DIR" ]; then
iota genesis
fi

echo "generate rosetta configuration"
iota-rosetta generate-rosetta-cli-config --online-url http://127.0.0.1:9002 --offline-url http://127.0.0.1:9003
Expand Down
4 changes: 2 additions & 2 deletions crates/iota-rosetta/resources/rosetta_cli.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"log_balance_changes": false,
"log_reconciliations": false,
"ignore_reconciliation_error": false,
"historical_balance_disabled": false,
"historical_balance_disabled": true,
"exempt_accounts": "",
"bootstrap_balances": "",
"interesting_accounts": "",
Expand All @@ -55,4 +55,4 @@
}
},
"perf": null
}
}

0 comments on commit 599ad39

Please sign in to comment.