node: update to last staging version

This commit is contained in:
ardocrat
2026-07-15 01:06:59 +03:00
parent 84a47ee59a
commit 2ebc8babc2
6 changed files with 349 additions and 592 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
[submodule "wallet"]
path = wallet
url = https://code.gri.mw/ardocrat/wallet
branch = grim-staging
branch = grim
[submodule "tor/webtunnel"]
path = tor/webtunnel
url = https://code.gri.mw/WEB/webtunnel
Generated
+323 -567
View File
File diff suppressed because it is too large Load Diff
+12 -13
View File
@@ -85,23 +85,22 @@ hyper-socks2 = "0.9.1"
hyper-proxy2 = "0.1.0"
hyper-tls = "0.6.0"
async-std = "1.13.2"
uuid = { version = "0.8.2", features = ["v4"] }
uuid = { version = "1.23.4", features = ["serde", "v4"] }
num-bigint = "0.4.6"
## tor
arti-client = { version = "0.43.0", features = ["static", "pt-client", "onion-service-service", "onion-service-client"] }
tor-rtcompat = { version = "0.43.0", features = ["static"] }
tor-config = "0.43.0"
fs-mistrust = "0.14.2"
tor-hsservice = "0.43.0"
tor-hsrproxy = "0.43.0"
tor-keymgr = "0.43.0"
tor-llcrypto = "0.43.0"
tor-hscrypto = "0.43.0"
arti-client = { version = "0.44.0", features = ["static", "pt-client", "onion-service-service", "onion-service-client"] }
tor-rtcompat = { version = "0.44.0", features = ["static"] }
tor-config = "0.44.0"
fs-mistrust = "0.15.0"
tor-hsservice = "0.44.0"
tor-hsrproxy = "0.44.0"
tor-keymgr = "0.44.0"
tor-llcrypto = "0.44.0"
tor-hscrypto = "0.44.0"
sha2 = "0.10.8"
ed25519-dalek = "2.1.1"
curve25519-dalek = "4.1.3"
safelog = "0.8.1"
ed25519-dalek = "2"
safelog = "0.9.0"
## stratum server
tokio-old = { version = "0.2", features = ["full"], package = "tokio" }
+1 -3
View File
@@ -12,7 +12,6 @@
// See the License for the specific language governing permissions and
// limitations under the License.
use futures::channel::oneshot;
use lazy_static::lazy_static;
use parking_lot::RwLock;
use std::path::{Path, PathBuf};
@@ -680,8 +679,7 @@ fn start_node_server() -> Result<Server, Error> {
}
// Start integrated node server.
let api_chan: &'static mut (oneshot::Sender<()>, oneshot::Receiver<()>) =
Box::leak(Box::new(oneshot::channel::<()>()));
let api_chan = tokio::sync::mpsc::channel::<()>(1);
let server_result = Server::new(server_config, None, None, api_chan);
server_result
}
+1 -1
View File
@@ -16,7 +16,7 @@ use arti_client::config::pt::TransportConfigBuilder;
use arti_client::config::{CfgPath, TorClientConfigBuilder};
use arti_client::{TorClient, TorClientConfig};
use bytes::Bytes;
use curve25519_dalek::digest::Digest;
use ed25519_dalek::Digest;
use ed25519_dalek::hazmat::ExpandedSecretKey;
use fs_mistrust::Mistrust;
use grin_util::secp::SecretKey;
+11 -7
View File
@@ -24,7 +24,6 @@ use crate::wallet::types::{
use crate::wallet::{ConnectionsConfig, Mnemonic, WalletConfig};
use chrono::Utc;
use futures::channel::oneshot;
use grin_api::{ApiServer, Router};
use grin_chain::SyncStatus;
use grin_keychain::{ExtKeychain, Keychain};
@@ -250,6 +249,8 @@ impl Wallet {
} else {
integrated()
};
let timeout = Duration::from_secs(60);
let client = if AppConfig::use_proxy() {
let socks = AppConfig::use_socks_proxy();
let url = if socks {
@@ -278,14 +279,19 @@ impl Wallet {
};
match addr_res {
None => HTTPNodeClient::new(&node_api_url, node_secret)?,
None => HTTPNodeClient::new(&node_api_url, node_secret, timeout)?,
Some(addr) => {
let scheme = if socks { "socks5://" } else { "http://" };
HTTPNodeClient::new_proxy(&node_api_url, node_secret, Some((addr, scheme)))?
HTTPNodeClient::new_proxy(
&node_api_url,
node_secret,
Some((addr, scheme)),
timeout,
)?
}
}
} else {
HTTPNodeClient::new(&node_api_url, node_secret)?
HTTPNodeClient::new(&node_api_url, node_secret, timeout)?
};
Ok(client)
}
@@ -2299,11 +2305,9 @@ fn start_api_server(wallet: &Wallet) -> Result<(ApiServer, u16), Error> {
.add_route("/v2/foreign", Arc::new(api_handler_v2))
.map_err(|_| Error::GenericError("Router failed to add route".to_string()))?;
let api_chan: &'static mut (oneshot::Sender<()>, oneshot::Receiver<()>) =
Box::leak(Box::new(oneshot::channel::<()>()));
let mut apis = ApiServer::new();
let socket_addr: SocketAddr = api_addr.parse().unwrap();
let api_chan = tokio::sync::mpsc::channel::<()>(1);
let _ = apis
.start(socket_addr, router, None, api_chan)
.map_err(|_| Error::GenericError("API thread failed to start".to_string()))?;