Skip to content

Commit f620d4d

Browse files
committed
feat(examples): update client builder to async
1 parent 85423cc commit f620d4d

File tree

5 files changed

+10
-5
lines changed
  • examples
    • client-cardano-database-v2/src
    • client-cardano-database/src
    • client-cardano-stake-distribution/src
    • client-cardano-transaction/src
    • client-mithril-stake-distribution/src

5 files changed

+10
-5
lines changed

examples/client-cardano-database-v2/src/main.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,8 @@ async fn main() -> MithrilResult<()> {
5757
.set_ancillary_verification_key(args.ancillary_verification_key)
5858
.with_origin_tag(Some("EXAMPLE".to_string()))
5959
.add_feedback_receiver(Arc::new(IndicatifFeedbackReceiver::new(&progress_bar)))
60-
.build()?;
60+
.build()
61+
.await?;
6162

6263
let cardano_database_snapshots = client.cardano_database_v2().list().await?;
6364

examples/client-cardano-database/src/main.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,8 @@ async fn main() -> MithrilResult<()> {
5656
.set_ancillary_verification_key(args.ancillary_verification_key)
5757
.with_origin_tag(Some("EXAMPLE".to_string()))
5858
.add_feedback_receiver(Arc::new(IndicatifFeedbackReceiver::new(&progress_bar)))
59-
.build()?;
59+
.build()
60+
.await?;
6061

6162
let snapshots = client.cardano_database().list().await?;
6263

examples/client-cardano-stake-distribution/src/main.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,8 @@ async fn main() -> MithrilResult<()> {
3737
ClientBuilder::aggregator(&args.aggregator_endpoint, &args.genesis_verification_key)
3838
.with_origin_tag(Some("EXAMPLE".to_string()))
3939
.with_logger(logger.clone())
40-
.build()?;
40+
.build()
41+
.await?;
4142

4243
let cardano_stake_distributions = client.cardano_stake_distribution().list().await?;
4344
info!(

examples/client-cardano-transaction/src/main.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,8 @@ async fn main() -> MithrilResult<()> {
4747
ClientBuilder::aggregator(&args.aggregator_endpoint, &args.genesis_verification_key)
4848
.with_origin_tag(Some("EXAMPLE".to_string()))
4949
.with_logger(logger.clone())
50-
.build()?;
50+
.build()
51+
.await?;
5152

5253
info!(logger, "Fetching a proof for the given transactions...",);
5354
let cardano_transaction_proof = client

examples/client-mithril-stake-distribution/src/main.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,8 @@ async fn main() -> MithrilResult<()> {
3737
ClientBuilder::aggregator(&args.aggregator_endpoint, &args.genesis_verification_key)
3838
.with_origin_tag(Some("EXAMPLE".to_string()))
3939
.with_logger(logger.clone())
40-
.build()?;
40+
.build()
41+
.await?;
4142

4243
let mithril_stake_distributions = client.mithril_stake_distribution().list().await?;
4344
info!(

0 commit comments

Comments
 (0)