try to update broker to sphinx-rs

This commit is contained in:
Evan Feenstra
2022-10-25 15:55:49 -07:00
parent 0106637090
commit 599fdd3dfa
6 changed files with 8 additions and 9 deletions

View File

@@ -8,7 +8,8 @@ default-run = "sphinx-key-broker"
strip = "debuginfo"
[dependencies]
sphinx-key-parser = { path = "../parser" }
sphinx-signer = { git = "https://github.com/stakwork/sphinx-rs" }
# sphinx-key-parser = { path = "../parser" }
vls-protocol = { git = "https://gitlab.com/lightning-signer/validating-lightning-signer.git" }
vls-proxy = { git = "https://gitlab.com/lightning-signer/validating-lightning-signer.git" }
vls-frontend = { git = "https://gitlab.com/lightning-signer/validating-lightning-signer.git" }

View File

@@ -1,7 +1,7 @@
use crate::{ChannelReply, ChannelRequest};
use async_trait::async_trait;
use rocket::tokio::sync::{mpsc, oneshot};
use sphinx_key_parser::topics;
use sphinx_signer::sphinx_glyph::topics;
use vls_protocol::{Error, Result};
use vls_protocol_client::SignerPort;

View File

@@ -8,7 +8,7 @@ use librumqttd::{
};
use rocket::tokio::time::timeout;
use rocket::tokio::{self, sync::broadcast, sync::mpsc};
use sphinx_key_parser::topics;
use sphinx_signer::sphinx_glyph::topics;
use std::sync::Arc;
use std::sync::{LazyLock, Mutex};
use std::time::Duration;

View File

@@ -9,7 +9,7 @@ use rocket::tokio::sync::{
mpsc::Sender,
};
use rocket::*;
use sphinx_key_parser::{error::Error as ParserError, topics};
use sphinx_signer::sphinx_glyph::{error::Error as GlyphError, topics};
use std::net::IpAddr::V4;
use std::net::Ipv4Addr;
@@ -37,7 +37,7 @@ async fn errors(error_tx: &State<broadcast::Sender<Vec<u8>>>, mut end: Shutdown)
loop {
let msg = select! {
msg = rx.recv() => match msg {
Ok(msg) => ParserError::from_slice(&msg[..]),
Ok(msg) => GlyphError::from_slice(&msg[..]),
Err(RecvError::Closed) => break,
Err(RecvError::Lagged(_)) => continue,
},

View File

@@ -3,10 +3,9 @@ use crate::routes::launch_rocket;
use crate::util::Settings;
use crate::ChannelRequest;
use rocket::tokio::{self, sync::broadcast, sync::mpsc};
use sphinx_key_parser as parser;
use sphinx_key_parser::topics;
use vls_protocol::serde_bolt::WireString;
use vls_protocol::{msgs, msgs::Message};
use sphinx_signer::{parser, sphinx_glyph::topics};
const CLIENT_ID: &str = "test-1";

View File

@@ -4,8 +4,7 @@ use bitcoin::blockdata::constants::ChainHash;
use log::*;
use rocket::tokio::sync::{mpsc, oneshot};
use secp256k1::PublicKey;
use sphinx_key_parser as parser;
use sphinx_key_parser::topics;
use sphinx_signer::{parser, sphinx_glyph::topics};
use std::thread;
use vls_protocol::{msgs, msgs::Message, Error, Result};
use vls_proxy::client::Client;