Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Extract the Engine trait #10958

Merged
merged 49 commits into from
Aug 15, 2019
Merged
Show file tree
Hide file tree
Changes from 46 commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
ddeef45
Add client-traits crate
dvdplm Aug 6, 2019
0d49c45
New crate `machine`
dvdplm Aug 6, 2019
0465e6b
Use new machine and client-traits crates in ethcore
dvdplm Aug 6, 2019
50ca45a
Use new crates machine and client-traits instead of ethcore where app…
dvdplm Aug 6, 2019
29d4095
Fix tests
dvdplm Aug 6, 2019
cd6e0e2
Don't re-export so many types from ethcore::client
dvdplm Aug 6, 2019
2477cbd
Fixing more fallout from removing re-export
dvdplm Aug 6, 2019
51ba2f4
Merge branch 'master' into dp/chore/move-machine-to-own-crate
dvdplm Aug 6, 2019
c84a01f
fix test
dvdplm Aug 7, 2019
f2497f4
More fallout from not re-exporting types
dvdplm Aug 7, 2019
1e43534
Add some docs
dvdplm Aug 7, 2019
6d83cf2
cleanup
dvdplm Aug 7, 2019
e04d188
import the macro edition style
dvdplm Aug 7, 2019
b6e91de
Merge branch 'master' into dp/chore/move-machine-to-own-crate
dvdplm Aug 7, 2019
bac7268
Tweak docs
dvdplm Aug 7, 2019
978eb88
Add missing import
dvdplm Aug 7, 2019
d6273a7
Merge branch 'master' into dp/chore/move-machine-to-own-crate
dvdplm Aug 8, 2019
18d6a94
remove unused ethabi_derive imports
dvdplm Aug 8, 2019
d5700d9
Use latest ethabi-contract
dvdplm Aug 8, 2019
83bb140
Move many traits from ethcore/client/traits to client-traits crate
dvdplm Aug 9, 2019
d96fff3
Move snapshot related traits to the engine crate (eew)
dvdplm Aug 9, 2019
33aa152
Move a few snapshot related types to common_types
dvdplm Aug 9, 2019
9b70856
fix warning
dvdplm Aug 9, 2019
f76e5ed
Gradually introduce new engine crate: snapshot
dvdplm Aug 9, 2019
5b3a8ca
ethcore typechecks with new engine crate
dvdplm Aug 9, 2019
cecd69c
Sort out types outside ethcore
dvdplm Aug 10, 2019
c5ab534
Add an EpochVerifier to ethash and use that in Engine.epoch_verifier()
dvdplm Aug 10, 2019
45c0497
Document pub members
dvdplm Aug 10, 2019
b11a21f
Sort out tests
dvdplm Aug 10, 2019
af485cc
Add test-helpers feature and move EngineSigner impl to the right place
dvdplm Aug 10, 2019
f617bcb
Sort out tests
dvdplm Aug 10, 2019
64b5c60
Sort out tests and refactor verification types
dvdplm Aug 10, 2019
b1b6b46
Fix missing traits
dvdplm Aug 10, 2019
881b71f
More missing traits
dvdplm Aug 10, 2019
ddca9ee
Fix tests and cleanup
dvdplm Aug 10, 2019
d7d3f4b
cleanup
dvdplm Aug 10, 2019
b2f8be6
Put back needed logger import
dvdplm Aug 10, 2019
8ab2a02
Don't rexport common_types from ethcore/src/client
dvdplm Aug 10, 2019
4aef5f2
Remove files no longer used
dvdplm Aug 10, 2019
951f63e
Get rid of itertools
dvdplm Aug 10, 2019
1c42cc1
Move a few more traits from ethcore to client-traits: BlockChainReset…
dvdplm Aug 10, 2019
07b1c2d
Move ProvingBlockChainClient to client-traits
dvdplm Aug 10, 2019
7e5e4bc
Don't re-export ForkChoice and Transition from ethcore
dvdplm Aug 10, 2019
b244bfb
Address grumbles: sort imports, remove commented out code
dvdplm Aug 13, 2019
37be7b2
Merge branch 'master' into dp/chore/extract-engine-trait
dvdplm Aug 13, 2019
88cfa7f
Fix merge resolution error
dvdplm Aug 13, 2019
dcaf256
Merge branch 'master' into dp/chore/extract-engine-trait
ordian Aug 15, 2019
60a03b2
merge failure
dvdplm Aug 15, 2019
c75738e
Merge branch 'master' into dp/chore/extract-engine-trait
dvdplm Aug 15, 2019
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
36 changes: 36 additions & 0 deletions Cargo.lock

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

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ jsonrpc-core = "12.0.0"
parity-bytes = "0.1"
client-traits = { path = "ethcore/client-traits" }
common-types = { path = "ethcore/types" }
engine = { path = "ethcore/engine" }
ethcore = { path = "ethcore", features = ["parity"] }
ethcore-accounts = { path = "accounts", optional = true }
ethcore-blockchain = { path = "ethcore/blockchain" }
Expand Down
2 changes: 1 addition & 1 deletion ethash/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ impl EthashManager {
EthashManager {
cache_dir: cache_dir.to_path_buf(),
nodecache_builder: NodeCacheBuilder::new(optimize_for.into().unwrap_or_default(), progpow_transition),
progpow_transition: progpow_transition,
progpow_transition,
cache: Mutex::new(LightCache {
recent_epoch: None,
recent: None,
Expand Down
18 changes: 10 additions & 8 deletions ethcore/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,13 @@ authors = ["Parity Technologies <admin@parity.io>"]

[dependencies]
account-db = { path = "account-db" }
account-state = { path = "account-state" }
ansi_term = "0.11"
blooms-db = { path = "../util/blooms-db", optional = true }
client-traits = { path = "./client-traits" }
common-types = { path = "types" }
crossbeam-utils = "0.6"
engine = { path = "./engine" }
env_logger = { version = "0.5", optional = true }
ethabi = "8.0"
ethabi-contract = "8.0"
Expand All @@ -30,10 +32,8 @@ ethereum-types = "0.6.0"
ethjson = { path = "../json" }
ethkey = { path = "../accounts/ethkey" }
evm = { path = "evm" }
trie-vm-factories = { path = "trie-vm-factories" }
futures = "0.1"
hash-db = "0.12.4"
parity-util-mem = "0.1"
itertools = "0.5"
journaldb = { path = "../util/journaldb" }
keccak-hash = "0.2.0"
Expand All @@ -51,43 +51,45 @@ memory-cache = { path = "../util/memory-cache" }
num_cpus = "1.2"
parity-bytes = "0.1"
parity-snappy = "0.1"
parity-util-mem = "0.1"
parking_lot = "0.8"
pod = { path = "pod" }
trie-db = "0.12.4"
patricia-trie-ethereum = { path = "../util/patricia-trie-ethereum" }
pod = { path = "pod" }
rand = "0.6"
rand_xorshift = "0.1.1"
rayon = "1.1"
rlp = "0.4.0"
rlp_derive = { path = "../util/rlp-derive" }
rustc-hex = "1.0"
serde = "1.0"
serde_derive = "1.0"
account-state = { path = "account-state" }
stats = { path = "../util/stats" }
state-db = { path = "state-db" }
stats = { path = "../util/stats" }
tempdir = { version = "0.3", optional = true }
time-utils = { path = "../util/time-utils" }
trace = { path = "trace" }
trace-time = "0.1"
trie-db = "0.12.4"
trie-vm-factories = { path = "trie-vm-factories" }
triehash-ethereum = { version = "0.2", path = "../util/triehash-ethereum" }
unexpected = { path = "../util/unexpected" }
using_queue = { path = "../miner/using-queue" }
vm = { path = "vm" }
rand_xorshift = "0.1.1"

[dev-dependencies]
blooms-db = { path = "../util/blooms-db" }
criterion = "0.2"
engine = { path = "./engine", features = ["test-helpers"] }
env_logger = "0.5"
ethcore-accounts = { path = "../accounts" }
fetch = { path = "../util/fetch" }
kvdb-rocksdb = "0.1.3"
machine = { path = "./machine", features = ["test-helpers"] }
parity-runtime = { path = "../util/runtime" }
rlp_compress = { path = "../util/rlp-compress" }
serde_json = "1.0"
tempdir = "0.3"
trie-standardmap = "0.12.4"
machine = { path = "./machine", features = ["test-helpers"] }

[features]
parity = ["work-notify", "price-info", "stratum"]
Expand Down
13 changes: 11 additions & 2 deletions ethcore/client-traits/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,15 @@ edition = "2018"
license = "GPL-3.0"

[dependencies]
ethereum-types = "0.6.0"
account-state = { path = "../account-state" }
blockchain = { package = "ethcore-blockchain", path = "../blockchain" }
bytes = { package = "parity-bytes", version = "0.1.0" }
call-contract = { package = "ethcore-call-contract", path = "../call-contract" }
common-types = { path = "../types" }

ethcore-db = { path = "../db" }
ethcore-miner = { path = "../../miner" }
ethereum-types = "0.6.0"
kvdb = "0.1.0"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sort?

stats = { path = "../../util/stats" }
trace = { path = "../trace" }
vm = { path = "../vm" }
Loading