Skip to content

Commit

Permalink
Merge pull request #3098 from Conflux-Chain/v2.0-stable-merge
Browse files Browse the repository at this point in the history
Merge for release v2.5.0.
  • Loading branch information
peilun-conflux authored Mar 2, 2025
2 parents eb77139 + 2b07b3f commit 7aa2e39
Show file tree
Hide file tree
Showing 252 changed files with 3,876 additions and 1,910 deletions.
607 changes: 335 additions & 272 deletions Cargo.lock

Large diffs are not rendered by default.

72 changes: 58 additions & 14 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@ members = [
"crates/cfx_bytes",
"crates/cfx_types",
"crates/cfx_addr",
"crates/cfx_math",
"crates/cfx_utils",
"crates/stratum",
"crates/accounts",
"crates/blockgen",
Expand All @@ -31,6 +29,7 @@ members = [
"crates/dbs/storage",
"crates/cfxcore/vm-interpreter",
"crates/cfxcore/vm-types",
"crates/util/cfx_math",
"crates/util/cfx-vm-tracer-derive",
"crates/util/dag",
"crates/util/delegate",
Expand All @@ -52,7 +51,7 @@ members = [
"crates/util/throttling",
"crates/util/treap-map",
"crates/util/version",
"crates/serde_utils",
"crates/util/serde_utils",
"crates/cfxcore/geth-tracer",
"crates/rpc/rpc-eth-types",
"crates/rpc/rpc-primitives",
Expand All @@ -62,12 +61,13 @@ members = [
"crates/rpc/rpc",
"crates/util/util-macros",
"crates/rpc/rpc-utils",
"crates/rpc/rpc-builder",
]

resolver = "2"

[workspace.package]
version = "2.4.1"
version = "2.5.0"
authors = ["peilun-conflux", "ChenxingLi"]
description = "A rust implementation of the Conflux-Protocol"
documentation = "https://doc.confluxnetwork.org"
Expand Down Expand Up @@ -97,7 +97,7 @@ debug-assertions = true

[workspace.dependencies]
cfxkey = { path = "./crates/cfx_key" }
cfx-math = { path = "./crates/cfx_math" }
cfx-math = { path = "./crates/util/cfx_math" }
solidity-abi = { path = "./crates/util/solidity-abi" }
random-crash = { path = "./crates/util/random_crash" }
memory-cache = { path = "./crates/util/memory-cache" }
Expand Down Expand Up @@ -126,7 +126,7 @@ client = { path = "./crates/client" }
cfx-stratum = { path = "./crates/stratum" }
txgen = { path = "./crates/transactiongen" }
blockgen = { path = "./crates/blockgen" }
serde-utils = { path = "./crates/serde_utils" }
serde-utils = { path = "./crates/util/serde_utils" }
db = { path = "./crates/dbs/db" }
cfx-db-errors = { path = "./crates/dbs/db-errors" }
cfx-statedb = { path = "./crates/dbs/statedb" }
Expand All @@ -137,7 +137,6 @@ cfxcore-accounts = { path = "./crates/accounts" }
secret-store = { path = "./crates/secret_store" }
cfxstore = { path = "./crates/cfx_store" }
network = { path = "./crates/network" }
cfx-utils = { path = "./crates/cfx_utils" }
cfxcore = { path = "./crates/cfxcore/core" }
cfx-parameters = { path = "./crates/cfxcore/parameters" }
cfx-execute-helper = { path = "./crates/cfxcore/execute-helper" }
Expand All @@ -155,19 +154,22 @@ cfx-rpc-eth-api = { path = "./crates/rpc/rpc-eth-api" }
cfx-util-macros = { path = "./crates/util/util-macros" }
cfx-rpc = { path = "./crates/rpc/rpc" }
cfx-rpc-utils = { path = "./crates/rpc/rpc-utils" }
cfx-rpc-builder = { path = "./crates/rpc/rpc-builder" }

serde = { version = "1.0", features = ["derive", "alloc"] }
serde_json = "1.0"
serde_derive = "1.0"
# proc-macros
proc-macro2 = "1.0"
quote = "1.0"

serde = { version = "1.0", features = ["derive", "alloc"], default-features = false }
serde_json = { version = "1.0", default-features = false, features = ["alloc"] }
serde_derive = { version = "1.0", default-features = false }
hex = "0.4.3"
rustc-hex = "2.1"
hex-literal = "0.4.1"

fail = "0.4.0"
thiserror = "1.0.63"
anyhow = "1.0"
error-chain = { version = "0.12" }
strum = "0.20"
strum_macros = "0.20"

# parallelism
parking_lot = "0.11"
Expand All @@ -192,9 +194,33 @@ jsonrpc-ws-server = "15.1.0"

# jsonrpc framework(new)
jsonrpsee = "0.24.4"
jsonrpsee-core = "0.24"
jsonrpsee-types = "0.24"

http = "1.0"

# async
tokio = "1.40"
tokio-stream = "0.1.11"
tokio-timer = "0.2.13"
tokio-util = "0.7.4"
tokio-test = "0.4.1"
futures = "0.3.30"
futures01 = "0.1"
futures-core = "0.3"
futures-util = "0.3"
hyper = "1.3"
hyper-util = "0.1.5"
async-stream = "0.3"
async-trait = "0.1"
async-oneshot = "0.5.0"
tower = "0.4"
tower-http = "0.5"
reqwest = { version = "0.12", default-features = false }
pin-project = "1.0.12"
mio = "0.6.8"
# old version tokio 0.2
tokio02 = { version = "0.2", package="tokio", features = ["full"] }

# crypto & hash
fixed-hash = "0.5"
Expand All @@ -207,15 +233,33 @@ secp256k1 = "0.30.0"
clap = "2"
rand = "0.7"
log = "0.4"
log4rs = "1.2.0"
env_logger = "0.11"
lazy_static = "1.4"
itertools = "0.10.0"
once_cell = "1.17.1"
chrono = "=0.4.38"
byteorder = "1.2.7"
strum = "0.26"
strum_macros = "0.26"
bytes = "1.9"
toml = "0.5.8"
textwrap = "0.9"
app_dirs = "1.2.1"
slab = "0.4"
tempdir = "0.3"
rpassword = "5.0.1"
static_assertions = "1.1.0"
transient-hashmap = "0.4"

bigdecimal = "0.1.0"
num-bigint = "0.2.6"
edit-distance = "2"
zeroize = "1"
docopt = "1.0"
env_logger = "0.5"
vergen = "7.0.0"
target_info = "0.1"
libc = "0.2"

# conflux forked crates
rocksdb = { git = "https://github.com/Conflux-Chain/rust-rocksdb.git", rev = "3773afe5b953997188f37c39308105b5deb0faac" }
Expand Down
11 changes: 6 additions & 5 deletions bins/cfx_store/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,15 @@ description = "Parity Ethereum Key Management CLI"
name = "cfxstore-cli"
version = "0.1.1"
authors = ["Parity Technologies <[email protected]>"]
edition = "2021"

[dependencies]
docopt = "1.0"
env_logger = "0.5"
env_logger = { workspace = true }
num_cpus = "1.6"
rustc-hex = "2.1"
serde = "1.0"
serde_derive = "1.0"
rustc-hex = { workspace = true }
serde = { workspace = true }
serde_derive = { workspace = true }
parking_lot = { workspace = true }
cfxstore = { workspace = true }
panic_hook = { workspace = true }
Expand All @@ -22,4 +23,4 @@ path = "src/main.rs"
doc = false

[dev-dependencies]
tempdir = "0.3"
tempdir = { workspace = true }
File renamed without changes.
15 changes: 1 addition & 14 deletions bins/cfx_store/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,6 @@
// You should have received a copy of the GNU General Public License
// along with Parity Ethereum. If not, see <http://www.gnu.org/licenses/>.

extern crate cfxstore;
extern crate dir;
extern crate docopt;
extern crate num_cpus;
extern crate panic_hook;
extern crate parking_lot;
extern crate rustc_hex;
extern crate serde;

extern crate env_logger;

#[macro_use]
extern crate serde_derive;

use std::{collections::VecDeque, env, fmt, fs, io::Read, process};

use cfxstore::{
Expand All @@ -41,6 +27,7 @@ use cfxstore::{
SimpleSecretStore, StoreAccountRef,
};
use docopt::Docopt;
use serde::Deserialize;

mod crack;

Expand Down
1 change: 0 additions & 1 deletion bins/cfx_store/tests/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
// You should have received a copy of the GNU General Public License
// along with Parity Ethereum. If not, see <http://www.gnu.org/licenses/>.

extern crate tempdir;
use std::{fs::File, io::Write, process::Command};
use tempdir::TempDir;

Expand Down
35 changes: 18 additions & 17 deletions bins/conflux/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,48 +8,49 @@ description.workspace = true
documentation.workspace = true

[dependencies]
# mio = { workspace = true }
clap = { workspace = true, features = ["yaml"] }
textwrap = "0.9"
toml = "0.5.8"
serde = "1.0"
serde_json = "1.0"
serde_derive = "1.0"
textwrap = { workspace = true }
toml = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
serde_derive = { workspace = true }
parking_lot = { workspace = true }
panic_hook = { workspace = true }
app_dirs = "1.2.1"
app_dirs = { workspace = true }
dir = { workspace = true }
cfxstore = { workspace = true }
cfxcore-accounts = { workspace = true }
home = "0.5.0"
rpassword = "4.0.1"
rpassword = { workspace = true }
io = { workspace = true }
ctrlc = { workspace = true }
jsonrpc-core = "18.0.0"
jsonrpc-tcp-server = "18.0.0"
jsonrpc-http-server = "18.0.0"
jsonrpc-core-client = { version = "18.0.0", features = ["http"] }
error-chain = { version = "0.12" }
log = "0.4"
slab = "0.4"
log = { workspace = true }
slab = { workspace = true }
cfxcore = { workspace = true }
network = { workspace = true }
db = { workspace = true }
blockgen = { workspace = true }
txgen = { workspace = true }
secret-store = { workspace = true }
primitives = { workspace = true }
log4rs = { version = "1.2.0", features = ["background_rotation", "gzip"] }
log4rs = { workspace = true, features = ["background_rotation", "gzip"] }
rlp = { workspace = true }
keccak-hash = { workspace = true }
rand = "0.8.3"
kvdb-rocksdb = { workspace = true }
client = { workspace = true }
cfx-types = { workspace = true }
docopt = "1.0"
threadpool = { workspace = true }
docopt = { workspace = true }
cfxkey = { workspace = true }
parity-wordlist = { workspace = true }
rustc-hex = "2.1"
env_logger = "0.5"
rustc-hex = { workspace = true }
env_logger = { workspace = true }
malloc_size_of = { workspace = true }
diem-crypto = { path= "../../crates/cfxcore/core/src/pos/crypto/crypto" }
diem-types = { path= "../../crates/cfxcore/core/src/pos/types" }
Expand All @@ -58,11 +59,11 @@ executor = { path = "../../crates/cfxcore/core/src/pos/consensus/executor" } #
storage-interface = { path = "../../crates/cfxcore/core/src/pos/storage/storage-interface" }
move-core-types = { path = "../../crates/cfxcore/core/src/pos/types/move-core-types" }
bcs = "0.1.3"
tempdir = "0.3.7"
hex = "0.3.0"
tempdir = { workspace = true }
hex = { workspace = true }
base64ct = "=1.1.1"
parity-version = { workspace = true }
tokio = { version = "1", features = ["rt"] }
tokio = { workspace = true, features = ["rt"] }
bls-signatures = { workspace = true }

[target.'cfg(not(target_env = "msvc"))'.dependencies.jemallocator]
Expand Down
5 changes: 2 additions & 3 deletions changelogs/JSONRPC.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@

## vNext

1. The gasUsed field of Core Space block will return `null` if the block is not executed.
2. Core Space pubsub block header notification add two new fields: `baseFeePerGas` and `custom`.

## v2.4.1

1. eSpace add new RPC method `eth_getBlockReceipts`
Expand All @@ -14,6 +11,8 @@
5. Optimize method name of test and debug namespace, add `test` and `debug` prefix, change name from underscore style to camel style eg `current_sync_phase` -> `debug_currentSyncPhase`.
6. eth_call, eth_estimateGas improve compatible with solidity custom revert error.
7. Update both core and eSpace block gas limit to return real available gas limit. The core space block size is 9/10 of the consensus block, and the eSpace block size is 5/10 of the total gas limit for all eSpace transaction blocks that can be packaged in the corresponding epoch.
8. The gasUsed field of Core Space block will return `null` if the block is not executed.
9. Core Space pubsub block header notification add two new fields: `baseFeePerGas` and `custom`.

Note: The `third` and `seventh` points above will cause changes in the data returned by the RPC, so please take note.

Expand Down
10 changes: 5 additions & 5 deletions crates/accounts/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ edition = "2021"
cfxkey = { workspace = true }
cfxstore = { workspace = true }
cfx-types = { workspace = true }
log = "0.4"
log = { workspace = true }
parking_lot = { workspace = true }
serde = "1.0"
serde_derive = "1.0"
serde_json = "1.0"
serde = { workspace = true }
serde_derive = { workspace = true }
serde_json = { workspace = true }

[dev-dependencies]
tempdir = "0.3"
tempdir = { workspace = true }
4 changes: 2 additions & 2 deletions crates/blockgen/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ network = { workspace = true }
primitives = { workspace = true }
parking_lot = { workspace = true }
rlp = { workspace = true }
rand = "0.7"
rand = { workspace = true }
secret-store = { workspace = true }
toml = "0.5.8"
toml = { workspace = true }
txgen = { workspace = true }
4 changes: 0 additions & 4 deletions crates/cfx_addr/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,6 @@ pub use consts::*;
pub use types::*;
pub use utils::*;

extern crate cfx_types;
extern crate core;
extern crate lazy_static;

#[cfg(not(feature = "std"))]
extern crate alloc;

Expand Down
1 change: 1 addition & 0 deletions crates/cfx_bytes/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ name = "cfx-bytes"
version = "0.1.0"
license = "GPL-3.0"
description = "Conflux bytes"
edition = "2021"

[dependencies]
ethcore-bytes = "0.1.1"
2 changes: 0 additions & 2 deletions crates/cfx_bytes/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,4 @@
// Conflux is free software and distributed under the
// GNU General Public License. See http://www.gnu.org/licenses/

extern crate ethcore_bytes;

pub use ethcore_bytes::{Bytes, BytesRef};
Loading

0 comments on commit 7aa2e39

Please sign in to comment.