@@ -8,7 +8,7 @@ use coinswap::{
88} ;
99use log:: LevelFilter ;
1010use serde_json:: { json, to_string_pretty} ;
11- use std:: { path:: PathBuf , str:: FromStr } ;
11+ use std:: { path:: PathBuf , str:: FromStr , thread , time :: Duration } ;
1212
1313#[ cfg( feature = "integration-test" ) ]
1414use coinswap:: taker:: TakerBehavior ;
@@ -35,7 +35,7 @@ struct Cli {
3535 name = "ADDRESS:PORT" ,
3636 long,
3737 short = 'r' ,
38- default_value = "127.0.0.1:38332 "
38+ default_value = "172.81.178.3:48332 "
3939 ) ]
4040 pub rpc : String ,
4141
@@ -44,7 +44,7 @@ struct Cli {
4444 name = "ZMQ" ,
4545 long,
4646 short = 'z' ,
47- default_value = "tcp://127.0.0.1:28332 "
47+ default_value = "tcp://172.81.178.3:58332 "
4848 ) ]
4949 pub zmq : String ,
5050
@@ -178,7 +178,7 @@ fn main() -> Result<(), TakerError> {
178178 let rpc_config = RPCConfig {
179179 url : args. rpc ,
180180 auth : Auth :: UserPass ( args. auth . 0 , args. auth . 1 ) ,
181- wallet_name : "random " . to_string ( ) , // we can put anything here as it will get updated in the init.
181+ wallet_name : "random_1 " . to_string ( ) , // we can put anything here as it will get updated in the init.
182182 } ;
183183
184184 match & args. command {
@@ -332,7 +332,10 @@ fn main() -> Result<(), TakerError> {
332332
333333 taker. get_wallet_mut ( ) . sync_and_save ( ) ?;
334334 }
335- Commands :: FetchOffers => {
335+ Commands :: FetchOffers => loop {
336+ // println!("I am here");
337+ // let makers= taker.watch_service.request_maker_address();
338+ // println!("{makers:#?}");
336339 let all_offers = {
337340 let offerbook = taker. fetch_offers ( ) ?;
338341 offerbook
@@ -343,15 +346,15 @@ fn main() -> Result<(), TakerError> {
343346 . collect :: < Vec < _ > > ( )
344347 } ;
345348 if all_offers. is_empty ( ) {
346- println ! ( "NO LIVE OFFERS FOUND!! You should run a maker!!" ) ;
347- return Ok ( ( ) ) ;
349+ // println!("NO LIVE OFFERS FOUND!! You should run a maker!!");
350+ thread :: sleep ( Duration :: from_secs ( 5 ) ) ;
348351 } else {
349352 all_offers. iter ( ) . try_for_each ( |offer| {
350353 println ! ( "{}" , taker. display_offer( offer) ?) ;
351354 Ok :: < _ , TakerError > ( ( ) )
352355 } ) ?;
353356 }
354- }
357+ } ,
355358 Commands :: Coinswap { makers, amount } => {
356359 // Note: taproot coinswap is handled at the top level to avoid
357360 // double Taker initialization. Regular ECDSA coinswap goes here.
0 commit comments