Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
142 changes: 11 additions & 131 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 8 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ members = [
"consensus/fast-sync",
"consensus/rules",

# Filesystem
"fs",

# Net
"net/epee-encoding",
"net/levin",
Expand Down Expand Up @@ -51,7 +54,7 @@ members = [
"test-utils",

# Fuzz
"fuzz"
"fuzz",
]

# Windows is a pain, so instead of making the fuzz tests work on windows, we just don't build the fuzz target on windows.
Expand All @@ -69,6 +72,9 @@ default-members = [
"consensus/fast-sync",
"consensus/rules",

# Filesystem
"fs",

# Net
"net/epee-encoding",
"net/levin",
Expand Down Expand Up @@ -137,6 +143,7 @@ cuprate-constants = { path = "constants", default-featur
cuprate-consensus = { path = "consensus", default-features = false }
cuprate-consensus-context = { path = "consensus/context", default-features = false }
cuprate-cryptonight = { path = "cryptonight", default-features = false }
cuprate-fs = { path = "fs", default-features = false }
cuprate-helper = { path = "helper", default-features = false }
cuprate-epee-encoding = { path = "net/epee-encoding", default-features = false }
cuprate-levin = { path = "net/levin", default-features = false }
Expand Down Expand Up @@ -175,7 +182,6 @@ bytemuck = { version = "1", default-features = false }
bytes = { version = "1", default-features = false }
cfg-if = { version = "1", default-features = false }
clap = { version = "4", default-features = false }
chrono = { version = "0.4", default-features = false }
crypto-bigint = { version = "0.5", default-features = false }
crossbeam = { version = "0.8", default-features = false }
const_format = { version = "0.2", default-features = false }
Expand Down
6 changes: 3 additions & 3 deletions binaries/cuprated/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ cuprate-database = { workspace = true, features = ["serde"] }
cuprate-epee-encoding = { workspace = true }
cuprate-fast-sync = { workspace = true }
cuprate-fixed-bytes = { workspace = true }
cuprate-helper = { workspace = true, features = ["std", "serde", "time", "net"] }
cuprate-fs = { workspace = true }
cuprate-helper = { workspace = true, features = ["std", "time", "net"] }
cuprate-hex = { workspace = true }
cuprate-json-rpc = { workspace = true }
cuprate-levin = { workspace = true }
Expand All @@ -33,7 +34,7 @@ cuprate-pruning = { workspace = true }
cuprate-rpc-interface = { workspace = true, features = ["dummy"] }
cuprate-rpc-types = { workspace = true, features = ["from"] }
cuprate-test-utils = { workspace = true }
cuprate-txpool = { workspace = true }
cuprate-txpool = { workspace = true, features = ["serde"] }
cuprate-types = { workspace = true, features = ["json"] }
cuprate-wire = { workspace = true }

Expand All @@ -48,7 +49,6 @@ bytemuck = { workspace = true }
bytes = { workspace = true }
cfg-if = { workspace = true }
clap = { workspace = true, features = ["cargo", "help", "wrap_help", "usage", "error-context", "suggestions"] }
chrono = { workspace = true }
crypto-bigint = { workspace = true }
crossbeam = { workspace = true }
curve25519-dalek = { workspace = true }
Expand Down
2 changes: 1 addition & 1 deletion binaries/cuprated/src/blockchain/fast_sync.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use std::slice;

use cuprate_helper::network::Network;
use cuprate_types::network::Network;

/// The hashes of the compiled in fast sync file.
///
Expand Down
2 changes: 1 addition & 1 deletion binaries/cuprated/src/blockchain/manager/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ use tower::BoxError;

use cuprate_consensus_context::{BlockchainContext, ContextConfig};
use cuprate_consensus_rules::{hard_forks::HFInfo, miner_tx::calculate_block_reward, HFsInfo};
use cuprate_helper::network::Network;
use cuprate_p2p::{block_downloader::BlockBatch, BroadcastSvc};
use cuprate_p2p_core::handles::HandleBuilder;
use cuprate_types::network::Network;
use cuprate_types::{CachedVerificationState, TransactionVerificationData, TxVersion};

use crate::blockchain::{
Expand Down
6 changes: 2 additions & 4 deletions binaries/cuprated/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,10 @@ use clap::Parser;
use serde::{Deserialize, Serialize};

use cuprate_consensus::ContextConfig;
use cuprate_helper::{
fs::{CUPRATE_CONFIG_DIR, DEFAULT_CONFIG_FILE_NAME},
network::Network,
};
use cuprate_fs::{CUPRATE_CONFIG_DIR, DEFAULT_CONFIG_FILE_NAME};
use cuprate_p2p::block_downloader::BlockDownloaderConfig;
use cuprate_p2p_core::ClearNet;
use cuprate_types::network::Network;

use crate::{
constants::{DEFAULT_CONFIG_STARTUP_DELAY, DEFAULT_CONFIG_WARNING},
Expand Down
2 changes: 1 addition & 1 deletion binaries/cuprated/src/config/args.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use std::{io::Write, path::PathBuf, process::exit};
use clap::builder::TypedValueParser;
use serde_json::Value;

use cuprate_helper::network::Network;
use cuprate_types::network::Network;

use crate::{config::Config, version::CupratedVersionInfo};

Expand Down
2 changes: 1 addition & 1 deletion binaries/cuprated/src/config/fs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use std::path::PathBuf;

use serde::{Deserialize, Serialize};

use cuprate_helper::fs::{CUPRATE_CACHE_DIR, CUPRATE_DATA_DIR};
use cuprate_fs::{CUPRATE_CACHE_DIR, CUPRATE_DATA_DIR};

use super::macros::config_struct;

Expand Down
3 changes: 2 additions & 1 deletion binaries/cuprated/src/config/p2p.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,13 @@ use std::{

use serde::{Deserialize, Serialize};

use cuprate_helper::{fs::address_book_path, network::Network};
use cuprate_fs::address_book_path;
use cuprate_p2p::config::TransportConfig;
use cuprate_p2p_core::{
transports::{Tcp, TcpServerConfig},
ClearNet, NetworkZone, Transport,
};
use cuprate_types::network::Network;
use cuprate_wire::OnionAddr;

use super::macros::config_struct;
Expand Down
2 changes: 1 addition & 1 deletion binaries/cuprated/src/config/storage.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use serde::{Deserialize, Serialize};

use cuprate_database::config::SyncMode;
use cuprate_database_service::ReaderThreads;
use cuprate_helper::fs::CUPRATE_DATA_DIR;
use cuprate_fs::CUPRATE_DATA_DIR;

use super::macros::config_struct;

Expand Down
2 changes: 1 addition & 1 deletion binaries/cuprated/src/logging.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ use tracing_subscriber::{
Layer, Registry,
};

use cuprate_helper::fs::logs_path;
use cuprate_fs::logs_path;

use crate::config::Config;

Expand Down
2 changes: 1 addition & 1 deletion books/architecture/src/resources/fs/paths.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Index of PATHs
This is an index of all of the filesystem PATHs Cuprate actively uses.

The [`cuprate_helper::fs`](https://doc.cuprate.org/cuprate_helper/fs/index.html)
The [`cuprate_fs`](https://doc.cuprate.org/cuprate_helper/fs/index.html)
module defines the general locations used throughout Cuprate.

[`dirs`](https://docs.rs/dirs) is used internally, which follows
Expand Down
Loading