mirror of
https://gitlab.com/pulsechaincom/lighthouse-pulse.git
synced 2025-01-12 14:00:06 +00:00
d01fe02824
## Issue Addressed
Resolves #2602
## Proposed Changes
*Note: For a review it might help to look at the individual commits.*
### `boot_node`
Add support for the flags `dump-config` and `immediate-shutdown`. For `immediate-shutdown` the actual behavior could be described as `dump-config-and-exit`.
Both flags are handled in `boot_node::main`, which appears to be the simplest approach.
### `boot_node` regression tests
Added in `lighthouse/tests/boot_node.rs`.
### `CommandLineTestExec`
Factors out boilerplate related to CLI tests. It's used in the regression tests for `boot_node`, `beacon_node` and `validator_client`.
## Open TODO
Add tests for `boot_node` flags `enable-enr-auto-update` and `disable-packet-filter`. They end up in [`Discv5Config`](9ed2cba6bc/boot_node/src/config.rs (L29)
), which doesn't support serde (de)serialization.
I haven't found a workaround - guidance would be appreciated.
59 lines
2.1 KiB
TOML
59 lines
2.1 KiB
TOML
[package]
|
|
name = "lighthouse"
|
|
version = "2.0.1"
|
|
authors = ["Sigma Prime <contact@sigmaprime.io>"]
|
|
edition = "2018"
|
|
autotests = false
|
|
|
|
[features]
|
|
# Writes debugging .ssz files to /tmp during block processing.
|
|
write_ssz_files = ["beacon_node/write_ssz_files"]
|
|
# Compiles the BLS crypto code so that the binary is portable across machines.
|
|
portable = ["bls/supranational-portable"]
|
|
# Compiles BLST so that it always uses ADX instructions.
|
|
modern = ["bls/supranational-force-adx"]
|
|
# Uses the slower Milagro BLS library, which is written in native Rust.
|
|
milagro = ["bls/milagro"]
|
|
# Support minimal spec (used for testing only).
|
|
spec-minimal = []
|
|
|
|
[dependencies]
|
|
beacon_node = { "path" = "../beacon_node" }
|
|
slog = { version = "2.5.2", features = ["max_level_trace"] }
|
|
sloggers = "2.0.2"
|
|
types = { "path" = "../consensus/types" }
|
|
bls = { path = "../crypto/bls" }
|
|
eth2_hashing = "0.2.0"
|
|
clap = "2.33.3"
|
|
env_logger = "0.9.0"
|
|
environment = { path = "./environment" }
|
|
boot_node = { path = "../boot_node" }
|
|
futures = "0.3.7"
|
|
validator_client = { "path" = "../validator_client" }
|
|
account_manager = { "path" = "../account_manager" }
|
|
clap_utils = { path = "../common/clap_utils" }
|
|
eth2_network_config = { path = "../common/eth2_network_config" }
|
|
lighthouse_version = { path = "../common/lighthouse_version" }
|
|
account_utils = { path = "../common/account_utils" }
|
|
lighthouse_metrics = { path = "../common/lighthouse_metrics" }
|
|
lazy_static = "1.4.0"
|
|
serde = { version = "1.0.116", features = ["derive"] }
|
|
serde_json = "1.0.59"
|
|
task_executor = { path = "../common/task_executor" }
|
|
malloc_utils = { path = "../common/malloc_utils" }
|
|
|
|
[dev-dependencies]
|
|
tempfile = "3.1.0"
|
|
validator_dir = { path = "../common/validator_dir" }
|
|
slashing_protection = { path = "../validator_client/slashing_protection" }
|
|
lighthouse_network = { path = "../beacon_node/lighthouse_network" }
|
|
|
|
[[test]]
|
|
name = "lighthouse_tests"
|
|
path = "tests/main.rs"
|
|
|
|
# Prevent cargo-udeps from flagging the dummy package `target_check`, which exists only
|
|
# to assert properties of the compilation target.
|
|
[package.metadata.cargo-udeps.ignore]
|
|
normal = ["target_check"]
|