replace log imports with tracing everywhere

This commit is contained in:
oars
2025-07-09 17:10:49 +03:00
parent b47fe86481
commit d85cf80dbf
169 changed files with 170 additions and 172 deletions

View File

@@ -21,8 +21,8 @@ use std::{
sync::Arc,
};
use log::{debug, error, info, warn};
use smol::lock::Mutex;
use tracing::{debug, error, info, warn};
use url::Url;
use darkfi::{

View File

@@ -18,9 +18,9 @@
use std::sync::Arc;
use log::{debug, error, info};
use smol::{fs::read_to_string, stream::StreamExt};
use structopt_toml::{serde::Deserialize, structopt::StructOpt, StructOptToml};
use tracing::{debug, error, info};
use url::Url;
use darkfi::{

View File

@@ -25,7 +25,7 @@ use darkfi::{
validator::ValidatorPtr,
Result,
};
use log::info;
use tracing::info;
/// Block proposal broadcast protocol
mod protocol_proposal;

View File

@@ -19,9 +19,9 @@
use std::{collections::HashSet, sync::Arc};
use async_trait::async_trait;
use log::{debug, error};
use smol::{channel::Sender, lock::RwLock};
use tinyjson::JsonValue;
use tracing::{debug, error};
use darkfi::{
impl_p2p_message,

View File

@@ -19,7 +19,7 @@
use std::sync::Arc;
use async_trait::async_trait;
use log::{debug, error};
use tracing::{debug, error};
use darkfi::{
blockchain::{BlockInfo, Header, HeaderHash},

View File

@@ -18,8 +18,8 @@
use std::sync::Arc;
use log::{debug, error};
use tinyjson::JsonValue;
use tracing::{debug, error};
use darkfi::{
net::{

View File

@@ -19,9 +19,9 @@
use std::{collections::HashSet, time::Instant};
use async_trait::async_trait;
use log::{debug, error, info, warn};
use smol::lock::MutexGuard;
use tinyjson::JsonValue;
use tracing::{debug, error, info, warn};
use url::Url;
use darkfi::{

View File

@@ -23,8 +23,8 @@ use darkfi_sdk::{
tx::TransactionHash,
};
use darkfi_serial::{deserialize_async, serialize_async};
use log::{debug, error};
use tinyjson::JsonValue;
use tracing::{debug, error};
use darkfi::{
rpc::jsonrpc::{

View File

@@ -17,8 +17,8 @@
*/
use darkfi_serial::deserialize_async;
use log::{error, warn};
use tinyjson::JsonValue;
use tracing::{error, warn};
use darkfi::{
rpc::jsonrpc::{

View File

@@ -19,8 +19,8 @@
use std::collections::HashMap;
use darkfi::rpc::jsonrpc::{ErrorCode, JsonError, JsonResponse, JsonResult};
use log::error;
use tinyjson::JsonValue;
use tracing::error;
use crate::DarkfiNode;

View File

@@ -30,7 +30,7 @@ use darkfi_sdk::{
pasta::{group::ff::PrimeField, pallas},
};
use darkfi_serial::serialize_async;
use log::{error, info};
use tracing::{error, info};
use crate::{
task::{garbage_collect_task, miner::MinerRewardsRecipientConfig, miner_task, sync_task},

View File

@@ -18,7 +18,7 @@
use darkfi::{error::TxVerifyFailed, validator::verification::verify_transactions, Error, Result};
use darkfi_sdk::crypto::MerkleTree;
use log::{debug, error, info};
use tracing::{debug, error, info};
use crate::DarkfiNodePtr;

View File

@@ -40,10 +40,10 @@ use darkfi_sdk::{
ContractCall,
};
use darkfi_serial::{serialize_async, Encodable};
use log::{error, info};
use num_bigint::BigUint;
use rand::rngs::OsRng;
use smol::channel::{Receiver, Sender};
use tracing::{error, info};
use crate::{proto::ProposalMessage, task::garbage_collect_task, DarkfiNodePtr};

View File

@@ -23,9 +23,9 @@ use darkfi::{
util::encoding::base64, validator::consensus::Proposal, Error, Result,
};
use darkfi_serial::serialize_async;
use log::{debug, info, warn};
use rand::{prelude::SliceRandom, rngs::OsRng};
use tinyjson::JsonValue;
use tracing::{debug, info, warn};
use crate::{
proto::{

View File

@@ -18,9 +18,9 @@
use std::{collections::HashSet, sync::Arc};
use log::{debug, error, info};
use smol::{channel::Receiver, lock::RwLock};
use tinyjson::JsonValue;
use tracing::{debug, error, info};
use darkfi::{
blockchain::BlockDifficulty,

View File

@@ -32,8 +32,8 @@ use darkfi_sdk::{
crypto::{pasta_prelude::FromUniformBytes, poseidon_hash, MerkleTree},
pasta::pallas,
};
use log::info;
use rand::{rngs::OsRng, CryptoRng, RngCore};
use tracing::info;
pub const RLN_APP_IDENTIFIER: pallas::Base = pallas::Base::from_raw([4242, 0, 0, 0]);
pub const RLN_TRAPDOOR_DERIVATION_PATH: pallas::Base = pallas::Base::from_raw([4211, 0, 0, 0]);

View File

@@ -39,7 +39,6 @@ use darkfi_sdk::{
};
use darkfi_serial::{deserialize_async, serialize_async};
use futures::FutureExt;
use log::{debug, error, info, warn};
use sled_overlay::sled;
use smol::{
io::{self, AsyncBufReadExt, AsyncWriteExt, BufReader},
@@ -47,6 +46,7 @@ use smol::{
net::SocketAddr,
prelude::{AsyncRead, AsyncWrite},
};
use tracing::{debug, error, info, warn};
use super::{
server::{IrcServer, MAX_MSG_LEN},

View File

@@ -52,7 +52,7 @@
use std::{collections::HashSet, sync::atomic::Ordering::SeqCst};
use darkfi::Result;
use log::{error, info};
use tracing::{error, info};
use super::{
client::{Client, ReplyType},

View File

@@ -38,7 +38,6 @@ use futures_rustls::{
rustls::{self, pki_types::PrivateKeyDer},
TlsAcceptor,
};
use log::{debug, error, info, warn};
use sled_overlay::sled;
use smol::{
fs,
@@ -47,6 +46,7 @@ use smol::{
prelude::{AsyncRead, AsyncWrite},
Executor,
};
use tracing::{debug, error, info, warn};
use url::Url;
use super::{client::Client, IrcChannel, IrcContact, Priv, Privmsg};

View File

@@ -33,12 +33,12 @@ use darkfi::{
};
use darkfi_sdk::crypto::pasta_prelude::PrimeField;
use log::{debug, error, info};
use rand::rngs::OsRng;
use settings::list_configured_contacts;
use sled_overlay::sled;
use smol::{fs, lock::Mutex, stream::StreamExt, Executor};
use structopt_toml::{serde::Deserialize, structopt::StructOpt, StructOptToml};
use tracing::{debug, error, info};
use url::Url;
const CONFIG_FILE: &str = "darkirc_config.toml";

View File

@@ -29,8 +29,8 @@ use darkfi::{
},
system::StoppableTaskPtr,
};
use log::debug;
use smol::lock::MutexGuard;
use tracing::debug;
use super::DarkIrc;

View File

@@ -25,7 +25,7 @@ use std::{
use crypto_box::PublicKey;
use darkfi::{Error::ParseFailed, Result};
use darkfi_sdk::{crypto::pasta_prelude::PrimeField, pasta::pallas};
use log::info;
use tracing::info;
use crate::{
crypto::rln::{closest_epoch, RlnIdentity},

View File

@@ -29,9 +29,9 @@ use darkfi_sdk::{
pasta::pallas,
};
use darkfi_serial::{deserialize, serialize};
use log::error;
use num_bigint::BigUint;
use sled_overlay::{sled, SledDbOverlay, SledDbOverlayStateDiff};
use tracing::error;
pub const SLED_SCANNED_BLOCKS_TREE: &[u8] = b"_scanned_blocks";
pub const SLED_STATE_INVERSE_DIFF_TREE: &[u8] = b"_state_inverse_diff";

View File

@@ -22,11 +22,11 @@ use std::{
str::FromStr,
};
use log::info;
use prettytable::{format, row, Table};
use rand::rngs::OsRng;
use smol::{fs::read_to_string, stream::StreamExt};
use structopt_toml::{serde::Deserialize, structopt::StructOpt, StructOptToml};
use tracing::info;
use url::Url;
use darkfi::{

View File

@@ -21,11 +21,11 @@ use std::{
sync::{Arc, Mutex},
};
use log::{debug, error};
use rusqlite::{
types::{ToSql, Value},
Connection,
};
use tracing::{debug, error};
use crate::error::{WalletDbError, WalletDbResult};

View File

@@ -22,9 +22,9 @@ use std::{
str::FromStr,
};
use log::{debug, error};
use serde::Deserialize;
use structopt::StructOpt;
use tracing::{debug, error};
use url::Url;
use darkfi::{rpc::settings::RpcSettingsOpt, util::file::load_file, Error, Result};

View File

@@ -18,7 +18,7 @@
use std::{fmt, sync::Arc};
use log::error;
use tracing::error;
use darkfi::{
error::RpcError,

View File

@@ -18,9 +18,9 @@
use std::{collections::HashSet, path::Path, sync::Arc};
use log::{error, info};
use smol::{lock::Mutex, stream::StreamExt};
use structopt_toml::{serde::Deserialize, structopt::StructOpt, StructOptToml};
use tracing::{error, info};
use url::Url;
use darkfi::{

View File

@@ -19,9 +19,9 @@
use std::{collections::HashSet, sync::Arc, time::Instant};
use async_trait::async_trait;
use log::{debug, error, trace, warn};
use smol::lock::{MutexGuard, RwLock};
use tinyjson::JsonValue;
use tracing::{debug, error, trace, warn};
use url::Url;
use darkfi::{

View File

@@ -16,9 +16,9 @@
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
use log::{debug, warn};
use sled_overlay::sled::{transaction::ConflictableTransactionError, Transactional};
use tinyjson::JsonValue;
use tracing::{debug, warn};
use darkfi::{
blockchain::{

View File

@@ -21,9 +21,9 @@ use std::{
str::FromStr,
};
use log::info;
use tar::Archive;
use tinyjson::JsonValue;
use tracing::info;
use darkfi::{
blockchain::BlockchainOverlay, validator::utils::deploy_native_contracts, Error, Result,

View File

@@ -18,7 +18,7 @@
use std::sync::Arc;
use log::debug;
use tracing::debug;
use darkfi::Result;

View File

@@ -38,8 +38,8 @@
use std::{sync::Arc, time::Instant};
use log::{debug, error, info, warn};
use tinyjson::JsonValue;
use tracing::{debug, error, info, warn};
use url::Url;
use darkfi::{

View File

@@ -18,9 +18,9 @@
use std::collections::HashMap;
use log::{debug, error};
use smol::io::Cursor;
use tinyjson::JsonValue;
use tracing::{debug, error};
use darkfi::{
blockchain::{

View File

@@ -18,8 +18,8 @@
use std::sync::{Arc, Mutex, MutexGuard};
use log::debug;
use sled_overlay::{sled, SledDbOverlay};
use tracing::debug;
use darkfi::{blockchain::SledDbOverlayPtr, Error, Result};
use darkfi_sdk::crypto::ContractId;

View File

@@ -21,8 +21,8 @@ use std::{
sync::{Arc, Mutex, MutexGuard},
};
use log::{debug, info};
use sled_overlay::{sled, SledDbOverlay};
use tracing::{debug, info};
use darkfi::{
blockchain::SledDbOverlayPtr,

View File

@@ -19,8 +19,8 @@
use std::collections::HashMap;
use lazy_static::lazy_static;
use log::info;
use sled_overlay::sled;
use tracing::info;
use darkfi::{blockchain::Blockchain, error::Result, util::path::expand_path};

View File

@@ -17,8 +17,6 @@
*/
use clap::{Parser, Subcommand};
use log::error;
use simplelog::{ColorChoice, TermLogger, TerminalMode};
use smol::lock::RwLock;
use std::{
collections::HashMap,
@@ -26,6 +24,7 @@ use std::{
sync::Arc,
};
use termcolor::{StandardStream, WriteColor};
use tracing::error;
use url::Url;
use darkfi::{

View File

@@ -23,11 +23,11 @@ use std::{
time::Duration,
};
use log::{error, info, warn};
use rand::{prelude::SliceRandom, rngs::OsRng};
use sha2::{Digest, Sha256};
use smol::lock::RwLock;
use tinyjson::JsonValue;
use tracing::{error, info, warn};
use url::Url;
use darkfi::{

View File

@@ -19,9 +19,9 @@
use std::sync::Arc;
use async_trait::async_trait;
use log::debug;
use num_bigint::BigUint;
use rand::{rngs::OsRng, Rng};
use tracing::debug;
use url::Url;
use darkfi::{

View File

@@ -23,11 +23,11 @@ use std::{
};
use futures::{future::FutureExt, pin_mut, select};
use log::{error, info, warn};
use rand::{
prelude::{IteratorRandom, SliceRandom},
rngs::OsRng,
};
use tracing::{error, info, warn};
use darkfi::{
dht::DhtNode,

View File

@@ -23,13 +23,13 @@ use std::{
sync::Arc,
};
use log::{error, info, warn};
use sled_overlay::sled;
use smol::{
channel,
fs::{self, OpenOptions},
lock::RwLock,
};
use tracing::{error, info, warn};
use darkfi::{
dht::{tasks as dht_tasks, Dht, DhtHandler, DhtSettings},

View File

@@ -16,11 +16,11 @@
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
use log::{debug, error, info, warn};
use sled_overlay::sled;
use smol::{stream::StreamExt, Executor};
use std::sync::Arc;
use structopt_toml::StructOptToml;
use tracing::{debug, error, info, warn};
use darkfi::{
async_daemonize,

View File

@@ -21,10 +21,10 @@ use std::{
sync::Arc,
};
use log::info;
use rand::rngs::OsRng;
use smol::lock::RwLock;
use structopt::StructOpt;
use tracing::info;
use url::Url;
use darkfi::{system::ExecutorPtr, Error, Result};

View File

@@ -17,9 +17,9 @@
*/
use async_trait::async_trait;
use log::{debug, error, info};
use smol::Executor;
use std::{path::StripPrefixError, sync::Arc};
use tracing::{debug, error, info};
use darkfi::{
dht::DhtHandler,

View File

@@ -17,7 +17,6 @@
*/
use async_trait::async_trait;
use log::error;
use smol::lock::{Mutex, MutexGuard};
use std::{
collections::{HashMap, HashSet},
@@ -25,6 +24,7 @@ use std::{
sync::Arc,
};
use tinyjson::JsonValue;
use tracing::error;
use darkfi::{
dht::DhtNode,

View File

@@ -18,7 +18,7 @@
use std::sync::Arc;
use log::{error, info, warn};
use tracing::{error, info, warn};
use darkfi::{
dht::{DhtHandler, DhtNode},

View File

@@ -23,8 +23,8 @@ use darkfi::{
};
use darkfi_serial::{deserialize, serialize};
use genevd::GenEvent;
use log::debug;
use tinyjson::JsonValue;
use tracing::debug;
pub struct Gen {
pub rpc_client: RpcClient,

View File

@@ -31,10 +31,10 @@ use darkfi::{
util::path::expand_path,
Error, Result,
};
use log::{debug, error, info};
use sled_overlay::sled;
use smol::{fs, lock::RwLock, stream::StreamExt};
use structopt_toml::{serde::Deserialize, structopt::StructOpt, StructOptToml};
use tracing::{debug, error, info};
mod rpc;
use rpc::JsonRpcInterface;

View File

@@ -19,9 +19,9 @@
use std::collections::HashSet;
use async_trait::async_trait;
use log::{debug, error};
use smol::lock::{Mutex, MutexGuard};
use tinyjson::JsonValue;
use tracing::{debug, error};
use darkfi::{
event_graph::{proto::EventPut, Event, EventGraphPtr},

View File

@@ -24,7 +24,6 @@ use std::{
};
use async_trait::async_trait;
use log::{debug, error, info, warn};
use semver::Version;
use smol::{
lock::{Mutex, MutexGuard},
@@ -35,6 +34,7 @@ use structopt::StructOpt;
use structopt_toml::StructOptToml;
use tinyjson::JsonValue;
use toml::Value;
use tracing::{debug, error, info, warn};
use url::Url;
use darkfi::{

View File

@@ -18,11 +18,11 @@
use std::{collections::HashSet, sync::Arc};
use log::{error, info};
use smol::{
channel::{Receiver, Sender},
lock::Mutex,
};
use tracing::{error, info};
use darkfi::{
rpc::{

View File

@@ -18,9 +18,9 @@
use std::sync::Arc;
use log::info;
use smol::{stream::StreamExt, Executor};
use structopt_toml::{serde::Deserialize, structopt::StructOpt, StructOptToml};
use tracing::info;
use darkfi::{async_daemonize, cli_desc, rpc::settings::RpcSettingsOpt, Error, Result};

View File

@@ -18,9 +18,9 @@
use std::collections::HashSet;
use log::{debug, error, info};
use num_bigint::BigUint;
use smol::lock::MutexGuard;
use tracing::{debug, error, info};
use darkfi::{
blockchain::BlockInfo,

View File

@@ -24,9 +24,9 @@ use std::{
};
use async_trait::async_trait;
use log::{debug, info, warn};
use smol::lock::{Mutex, MutexGuard};
use tinyjson::JsonValue;
use tracing::{debug, info, warn};
use darkfi::{
event_graph::EventGraphPtr,

View File

@@ -36,12 +36,12 @@ use darkfi_serial::{
};
use futures::{select, FutureExt};
use libc::mkfifo;
use log::{debug, error, info};
use rand::rngs::OsRng;
use sled_overlay::sled;
use smol::{fs, stream::StreamExt};
use structopt_toml::StructOptToml;
use tinyjson::JsonValue;
use tracing::{debug, error, info};
use darkfi::{
async_daemonize,

View File

@@ -23,8 +23,8 @@ use std::{
};
use chrono::{TimeZone, Utc};
use log::debug;
use tinyjson::JsonValue;
use tracing::debug;
use darkfi::util::{
file::{load_json_file, save_json_file},

View File

@@ -24,8 +24,8 @@ use std::{
};
use darkfi_serial::{async_trait, SerialDecodable, SerialEncodable};
use log::debug;
use tinyjson::JsonValue;
use tracing::debug;
use darkfi::{
util::{

View File

@@ -22,7 +22,7 @@ use std::{
path::Path,
};
use log::debug;
use tracing::debug;
use darkfi::{Error, Result};
use rand::{distributions::Alphanumeric, rngs::OsRng, Rng};

View File

@@ -17,9 +17,9 @@
*/
// ANCHOR: imports
use log::{debug, error, info};
use smol::{lock::Mutex, stream::StreamExt};
use std::{collections::HashSet, sync::Arc};
use tracing::{debug, error, info};
use darkfi::{
async_daemonize, cli_desc, net,

View File

@@ -19,9 +19,9 @@
// ANCHOR: protocol_dchat
use async_trait::async_trait;
use darkfi::{net, Result};
use log::debug;
use smol::Executor;
use std::sync::Arc;
use tracing::debug;
use crate::dchatmsg::{DchatMsg, DchatMsgsBuffer};

View File

@@ -18,9 +18,9 @@
use async_trait::async_trait;
use darkfi::{net::P2pPtr, system::StoppableTaskPtr};
use log::debug;
use smol::lock::MutexGuard;
use std::collections::HashSet;
use tracing::debug;
use darkfi::rpc::{
jsonrpc::{ErrorCode, JsonError, JsonRequest, JsonResponse, JsonResult},

View File

@@ -39,7 +39,7 @@ use darkfi::{
};
use darkfi_serial::{AsyncDecodable, AsyncEncodable};
use futures::{FutureExt, AsyncWriteExt};
use log::{debug, error, info};
use tracing::{debug, error, info};
use sled_overlay::sled;
use smol::{fs, lock::Mutex, stream::StreamExt, Executor};
use std::{collections::HashSet, path::PathBuf, sync::Arc};

View File

@@ -29,7 +29,7 @@ use darkfi::{
},
system::StoppableTaskPtr,
};
use log::debug;
use tracing::debug;
use smol::lock::MutexGuard;
use super::Daemon;

View File

@@ -26,7 +26,7 @@ use darkfi_serial::{
async_trait, deserialize_async_partial, AsyncDecodable, AsyncEncodable, SerialDecodable,
SerialEncodable,
};
use log::{error, info};
use tracing::{error, info};
use sled_overlay::sled;
use smol::fs;
use url::Url;

View File

@@ -27,7 +27,7 @@ use darkfi::{
use darkfi_serial::{
async_trait, deserialize_async, serialize_async, SerialDecodable, SerialEncodable,
};
use log::{debug, error, info};
use tracing::{debug, error, info};
use sled_overlay::{sled, SledTreeOverlay};
use smol::{
lock::{OnceCell, RwLock},

View File

@@ -18,9 +18,9 @@
use std::{fmt, sync::Arc};
use log::info;
use smol::stream::StreamExt;
use structopt_toml::{serde::Deserialize, structopt::StructOpt, StructOptToml};
use tracing::info;
use url::Url;
use darkfi::{

View File

@@ -27,7 +27,7 @@ use darkfi::{
system::{ExecutorPtr, Publisher, StoppableTask},
Error, Result,
};
use log::{error, info};
use tracing::{error, info};
use url::Url;
use crate::DamCli;

View File

@@ -27,9 +27,9 @@ use darkfi::{
system::{ExecutorPtr, StoppableTask, StoppableTaskPtr},
Error, Result,
};
use log::{debug, error, info};
use smol::lock::Mutex;
use tinyjson::JsonValue;
use tracing::{debug, error, info};
use crate::proto::{
protocol_bar::Bar,

View File

@@ -21,8 +21,8 @@ use std::{
sync::Arc,
};
use log::{debug, error, info};
use smol::lock::Mutex;
use tracing::{debug, error, info};
use darkfi::{
net::settings::Settings,

View File

@@ -19,9 +19,9 @@
use std::sync::Arc;
use async_std::prelude::StreamExt;
use log::info;
use smol::Executor;
use structopt_toml::{serde::Deserialize, structopt::StructOpt, StructOptToml};
use tracing::info;
use darkfi::{
async_daemonize, cli_desc, net::settings::SettingsOpt, rpc::settings::RpcSettingsOpt, Error,

View File

@@ -24,7 +24,7 @@ use darkfi::{
system::ExecutorPtr,
Result,
};
use log::info;
use tracing::info;
/// `Foo` messages broadcast protocol
pub mod protocol_foo;

View File

@@ -19,8 +19,8 @@
use std::sync::Arc;
use async_trait::async_trait;
use log::{debug, error, info};
use tinyjson::JsonValue;
use tracing::{debug, error, info};
use darkfi::{
impl_p2p_message,

View File

@@ -19,8 +19,8 @@
use std::sync::Arc;
use async_trait::async_trait;
use log::{debug, error, info};
use tinyjson::JsonValue;
use tracing::{debug, error, info};
use darkfi::{
impl_p2p_message,

View File

@@ -19,8 +19,8 @@
use std::collections::HashSet;
use async_trait::async_trait;
use log::debug;
use smol::lock::MutexGuard;
use tracing::debug;
use darkfi::{
net::P2pPtr,

View File

@@ -18,7 +18,7 @@
use std::{collections::HashSet, sync::Arc};
use log::{error, info};
use tracing::{error, info};
use rand::{rngs::OsRng, Rng};
use smol::{stream::StreamExt, Executor};
use structopt_toml::{serde::Deserialize, structopt::StructOpt, StructOptToml};

View File

@@ -18,8 +18,8 @@
use std::{collections::HashSet, sync::Arc};
use log::{error, info};
use smol::lock::Mutex;
use tracing::{error, info};
use url::Url;
use darkfi::{

View File

@@ -19,8 +19,8 @@
use std::sync::Arc;
use async_std::prelude::StreamExt;
use log::info;
use structopt_toml::{serde::Deserialize, structopt::StructOpt, StructOptToml};
use tracing::info;
use url::Url;
use darkfi::{async_daemonize, cli_desc, rpc::settings::RpcSettingsOpt, Error, Result};

View File

@@ -30,9 +30,9 @@ use darkfi::{
};
use darkfi_sdk::{crypto::pasta_prelude::PrimeField, pasta::pallas};
use darkfi_serial::serialize;
use log::{debug, error, info};
use smol::lock::MutexGuard;
use tinyjson::JsonValue;
use tracing::{debug, error, info};
use url::Url;
use crate::{

View File

@@ -26,8 +26,8 @@ use darkfi_sdk::{
monotree::Monotree,
};
use darkfi_serial::{deserialize, serialize};
use log::{debug, error};
use sled_overlay::{serial::parse_record, sled, SledDbOverlay};
use tracing::{debug, error};
use crate::{
zk::{empty_witnesses, VerifyingKey, ZkCircuit},

View File

@@ -19,8 +19,8 @@
use std::sync::{Arc, Mutex};
use darkfi_sdk::{monotree::Monotree, tx::TransactionHash};
use log::debug;
use sled_overlay::{sled, sled::Transactional};
use tracing::debug;
use crate::{tx::Transaction, util::time::Timestamp, Error, Result};

View File

@@ -21,8 +21,8 @@ use darkfi_sdk::{
pasta::pallas,
};
use log::debug;
use rand::rngs::OsRng;
use tracing::debug;
use darkfi::{
zk::{halo2::Value, Proof, ProvingKey, Witness, ZkCircuit},

View File

@@ -22,8 +22,8 @@ use darkfi::{
Result,
};
use darkfi_sdk::{crypto::SecretKey, pasta::pallas};
use log::debug;
use rand::rngs::OsRng;
use tracing::debug;
use crate::model::{Dao, DaoMintParams};

View File

@@ -30,8 +30,8 @@ use darkfi_sdk::{
},
pasta::pallas,
};
use log::debug;
use rand::rngs::OsRng;
use tracing::debug;
use darkfi::{
zk::{halo2::Value, Proof, ProvingKey, Witness, ZkCircuit},

View File

@@ -37,8 +37,8 @@ use darkfi_sdk::{
},
pasta::pallas,
};
use log::info;
use rand::rngs::OsRng;
use tracing::info;
// Integration test configuration
// Holders this test will use:

View File

@@ -18,7 +18,7 @@
use darkfi::{ClientFailed, Result};
use darkfi_sdk::{crypto::Keypair, deploy::DeployParamsV1};
use log::{debug, error};
use tracing::{debug, error};
use crate::error::DeployError;

View File

@@ -18,7 +18,7 @@
use darkfi::Result;
use darkfi_sdk::crypto::Keypair;
use log::debug;
use tracing::debug;
use crate::model::LockParamsV1;

View File

@@ -18,7 +18,7 @@
use darkfi::Result;
use darkfi_contract_test_harness::{init_logger, Holder, TestHarness};
use log::info;
use tracing::info;
#[test]
fn deploy_integration() -> Result<()> {

View File

@@ -22,8 +22,8 @@ use darkfi::{
Result,
};
use darkfi_sdk::crypto::Keypair;
use log::debug;
use rand::rngs::OsRng;
use tracing::debug;
use crate::model::{MoneyAuthTokenFreezeParamsV1, TokenAttributes};

View File

@@ -22,8 +22,8 @@ use darkfi::{
Result,
};
use darkfi_sdk::crypto::{note::AeadEncryptedNote, Blind, Keypair};
use log::debug;
use rand::rngs::OsRng;
use tracing::debug;
use crate::{
client::MoneyNote,

View File

@@ -25,8 +25,8 @@ use darkfi_sdk::{
crypto::{note::AeadEncryptedNote, pasta_prelude::*, Blind, FuncId, PublicKey},
pasta::pallas,
};
use log::debug;
use rand::{prelude::SliceRandom, rngs::OsRng};
use tracing::debug;
use crate::{
client::{

View File

@@ -26,8 +26,8 @@ use darkfi_sdk::{
crypto::{note::AeadEncryptedNote, pasta_prelude::*, Blind, FuncId, PublicKey},
pasta::pallas,
};
use log::debug;
use rand::rngs::OsRng;
use tracing::debug;
use crate::{
client::{

View File

@@ -31,8 +31,8 @@ use darkfi_sdk::{
pasta::pallas,
};
use darkfi_serial::serialize;
use log::{debug, error};
use rand::rngs::OsRng;
use tracing::{debug, error};
use crate::{
client::{

View File

@@ -22,8 +22,8 @@ use darkfi::{
Result,
};
use darkfi_sdk::pasta::pallas;
use log::debug;
use rand::rngs::OsRng;
use tracing::debug;
use crate::model::{CoinAttributes, MoneyTokenMintParamsV1, TokenAttributes};

View File

@@ -28,8 +28,8 @@ use darkfi_sdk::{
},
pasta::pallas,
};
use log::debug;
use rand::rngs::OsRng;
use tracing::debug;
use super::proof::{create_transfer_burn_proof, create_transfer_mint_proof};
use crate::{

View File

@@ -21,8 +21,8 @@ use darkfi_sdk::{
crypto::{pasta_prelude::*, Blind, FuncId, Keypair, MerkleTree, PublicKey},
pasta::pallas,
};
use log::{debug, error};
use rand::{prelude::SliceRandom, rngs::OsRng};
use tracing::{debug, error};
use crate::{
client::OwnCoin,

View File

@@ -29,8 +29,8 @@ use darkfi_sdk::{
},
pasta::pallas,
};
use log::debug;
use rand::rngs::OsRng;
use tracing::debug;
use super::{TransferCallInput, TransferCallOutput};
use crate::model::{Coin, CoinAttributes, Nullifier};

View File

@@ -27,7 +27,7 @@
use darkfi::Result;
use darkfi_contract_test_harness::{init_logger, Holder, TestHarness};
use log::info;
use tracing::info;
#[test]
fn genesis_mint() -> Result<()> {

View File

@@ -30,8 +30,8 @@
use darkfi::Result;
use darkfi_contract_test_harness::{init_logger, Holder, TestHarness};
use darkfi_sdk::crypto::BaseBlind;
use log::info;
use rand::rngs::OsRng;
use tracing::info;
#[test]
fn mint_pay_swap() -> Result<()> {

View File

@@ -19,8 +19,8 @@
use darkfi::Result;
use darkfi_contract_test_harness::{init_logger, Holder, TestHarness};
use darkfi_sdk::crypto::BaseBlind;
use log::info;
use rand::rngs::OsRng;
use tracing::info;
#[test]
fn token_mint() -> Result<()> {

Some files were not shown because too many files have changed in this diff Show More