mirror of
https://github.com/RoboSats/taptrade-core.git
synced 2025-07-23 11:13:17 +00:00
fix broken imports
This commit is contained in:
29
taptrade-cli-demo/coordinator/Cargo.lock
generated
29
taptrade-cli-demo/coordinator/Cargo.lock
generated
@ -309,6 +309,7 @@ dependencies = [
|
||||
"serde",
|
||||
"sqlx",
|
||||
"tokio",
|
||||
"tower",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@ -711,6 +712,12 @@ dependencies = [
|
||||
"unicode-segmentation",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "hermit-abi"
|
||||
version = "0.3.9"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024"
|
||||
|
||||
[[package]]
|
||||
name = "hex"
|
||||
version = "0.4.3"
|
||||
@ -1113,6 +1120,16 @@ dependencies = [
|
||||
"libm",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "num_cpus"
|
||||
version = "1.16.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43"
|
||||
dependencies = [
|
||||
"hermit-abi",
|
||||
"libc",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "object"
|
||||
version = "0.36.0"
|
||||
@ -1697,6 +1714,15 @@ dependencies = [
|
||||
"digest",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "signal-hook-registry"
|
||||
version = "1.4.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "a9e9e0b4211b72e7b8b6e85c807d36c212bdb33ea8587f7569562a84df5465b1"
|
||||
dependencies = [
|
||||
"libc",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "signature"
|
||||
version = "2.2.0"
|
||||
@ -2099,7 +2125,10 @@ dependencies = [
|
||||
"bytes",
|
||||
"libc",
|
||||
"mio",
|
||||
"num_cpus",
|
||||
"parking_lot 0.12.3",
|
||||
"pin-project-lite",
|
||||
"signal-hook-registry",
|
||||
"socket2",
|
||||
"tokio-macros",
|
||||
"windows-sys 0.48.0",
|
||||
|
@ -5,17 +5,16 @@ edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
anyhow = "1.0.86"
|
||||
axum = "0.7.5"
|
||||
axum = { version = "0.7.5", features = ["tokio", "json"] }
|
||||
bdk = "0.29.0"
|
||||
dotenv = "0.15.0"
|
||||
reqwest = { version = "0.12.4", features = ["blocking", "json"] }
|
||||
serde = "1.0.203"
|
||||
sqlx = { version = "0.7.4", features = ["runtime-tokio", "sqlite"] }
|
||||
tokio = "1.38.0"
|
||||
tokio = { version = "1.38.0", features = ["full"] }
|
||||
tower = "0.4.13"
|
||||
|
||||
[profile.release]
|
||||
lto = true
|
||||
opt-level = 3
|
||||
strip = true
|
||||
anyhow = "1.0.86"
|
||||
hex = "0.4"
|
||||
|
@ -1,18 +1,17 @@
|
||||
mod api;
|
||||
|
||||
use reqwest::StatusCode;
|
||||
use axum::{routing::post, Json, Router, response::{IntoResponse, Response}, };
|
||||
use self::api::*;
|
||||
use super::*;
|
||||
use axum::{
|
||||
http::StatusCode,
|
||||
response::{IntoResponse, Response},
|
||||
routing::post,
|
||||
Extension, Json, Router,
|
||||
};
|
||||
use serde::{Deserialize, Serialize};
|
||||
use std::net::SocketAddr;
|
||||
use tokio::net::TcpListener;
|
||||
// use super::*;
|
||||
// use api::{BondRequirementResponse, BondSubmissionRequest, OrderActivatedResponse, OrderRequest};
|
||||
// use axum::{
|
||||
// http::StatusCode, response::IntoResponse, response::Response, routing::post, Extension, Json,
|
||||
// Router,
|
||||
// };
|
||||
// use sqlx::sqlite::SqliteLockingMode;
|
||||
use crate::verify_bond::verify_psbt;
|
||||
// use crate::coordinator::verify_psbt;
|
||||
|
||||
// Handler function to process the received data
|
||||
async fn receive_order(
|
||||
|
@ -6,7 +6,6 @@ use bdk::database::MemoryDatabase;
|
||||
use bdk::Wallet;
|
||||
use communication::api_server;
|
||||
use dotenv::dotenv;
|
||||
use serde::{Deserialize, Serialize};
|
||||
use sqlx::{sqlite::SqlitePoolOptions, Pool, Sqlite};
|
||||
use std::env;
|
||||
use std::sync::Arc;
|
||||
@ -28,11 +27,11 @@ async fn main() -> Result<()> {
|
||||
.unwrap();
|
||||
let shared_db_pool: Arc<sqlx::Pool<sqlx::Sqlite>> = Arc::new(db_pool);
|
||||
|
||||
let coordinator = Coordinator {
|
||||
db_pool: shared_db_pool,
|
||||
wallet: // impl wallet
|
||||
};
|
||||
// let coordinator = Coordinator {
|
||||
// db_pool: shared_db_pool,
|
||||
// wallet: // impl wallet
|
||||
// };
|
||||
|
||||
api_server(coordinator).await?;
|
||||
// api_server(coordinator).await?;
|
||||
Ok(())
|
||||
}
|
||||
|
@ -7,11 +7,7 @@ use crate::{
|
||||
wallet::{bond::Bond, musig2::MuSigData},
|
||||
};
|
||||
use anyhow::{anyhow, Result};
|
||||
use api::{
|
||||
BondRequirementResponse, BondSubmissionRequest, IsOfferReadyRequest, OfferTakenRequest,
|
||||
OfferTakenResponse, OrderActivatedResponse, OrderRequest, PayoutPsbtResponse,
|
||||
PsbtSubmissionRequest, TradeObligationsSatisfied,
|
||||
};
|
||||
use api::*;
|
||||
use bdk::bitcoin::consensus::encode::serialize_hex;
|
||||
use bdk::{
|
||||
bitcoin::{consensus::Encodable, psbt::PartiallySignedTransaction},
|
||||
|
@ -4,10 +4,9 @@ mod communication;
|
||||
mod trading;
|
||||
mod wallet;
|
||||
|
||||
use core::panic;
|
||||
|
||||
use anyhow::{anyhow, Result};
|
||||
use cli::CliSettings;
|
||||
use core::panic;
|
||||
|
||||
fn start_trade_pipeline(cli_input: &CliSettings) -> Result<()> {
|
||||
match cli_input {
|
||||
|
Reference in New Issue
Block a user