From 31b9d0517f88a1f857c51586fcd08b7cc248f997 Mon Sep 17 00:00:00 2001 From: Andrew McKenzie Date: Fri, 20 Dec 2024 16:21:30 +0000 Subject: [PATCH] remove need to pull helium-lib into iot config --- iot_config/src/client/sub_dao_client.rs | 5 ++--- iot_verifier/src/rewarder.rs | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/iot_config/src/client/sub_dao_client.rs b/iot_config/src/client/sub_dao_client.rs index 000be0d00..57254d82b 100644 --- a/iot_config/src/client/sub_dao_client.rs +++ b/iot_config/src/client/sub_dao_client.rs @@ -2,7 +2,6 @@ use super::{call_with_retry, ClientError, Settings}; use crate::sub_dao_epoch_reward_info::EpochRewardInfo; use file_store::traits::MsgVerify; use helium_crypto::{Keypair, PublicKey, Sign}; -use helium_lib::keypair::Pubkey; use helium_proto::{ services::{ sub_dao::{self, SubDaoEpochRewardInfoReqV1}, @@ -40,7 +39,7 @@ pub trait SubDaoEpochRewardInfoResolver: Clone + Send + Sync + 'static { async fn resolve_info( &self, - sub_dao: &Pubkey, + sub_dao: &str, epoch: u64, ) -> Result, Self::Error>; } @@ -51,7 +50,7 @@ impl SubDaoEpochRewardInfoResolver for SubDaoClient { async fn resolve_info( &self, - sub_dao: &Pubkey, + sub_dao: &str, epoch: u64, ) -> Result, Self::Error> { let mut request = SubDaoEpochRewardInfoReqV1 { diff --git a/iot_verifier/src/rewarder.rs b/iot_verifier/src/rewarder.rs index fa833a6d1..e194f3730 100644 --- a/iot_verifier/src/rewarder.rs +++ b/iot_verifier/src/rewarder.rs @@ -136,7 +136,7 @@ where pub async fn reward(&mut self, next_reward_epoch: u64) -> anyhow::Result<()> { let reward_info = self .sub_dao_epoch_reward_client - .resolve_info(&self.sub_dao, next_reward_epoch) + .resolve_info(&self.sub_dao.to_string(), next_reward_epoch) .await? .ok_or(anyhow::anyhow!( "No reward info found for epoch {}",