mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 04:41:03 +00:00
substrate: sysinfo: Expose failed hardware requirements (#2144)
The check_hardware functions does not give us too much information as to what is failing, so let's return the list of failed metrics, so that callers can print it. This would make debugging easier, rather than try to guess which dimension is actually failing. Signed-off-by: Alexandru Gheorghe <alexandru.gheorghe@parity.io>
This commit is contained in:
committed by
GitHub
parent
e9987401f3
commit
dca142398e
@@ -1955,10 +1955,11 @@ pub async fn start_contracts_rococo_node(
|
||||
fn warn_if_slow_hardware(hwbench: &sc_sysinfo::HwBench) {
|
||||
// Polkadot para-chains should generally use these requirements to ensure that the relay-chain
|
||||
// will not take longer than expected to import its blocks.
|
||||
if !frame_benchmarking_cli::SUBSTRATE_REFERENCE_HARDWARE.check_hardware(hwbench) {
|
||||
if let Err(err) = frame_benchmarking_cli::SUBSTRATE_REFERENCE_HARDWARE.check_hardware(hwbench) {
|
||||
log::warn!(
|
||||
"⚠️ The hardware does not meet the minimal requirements for role 'Authority' find out more at:\n\
|
||||
https://wiki.polkadot.network/docs/maintain-guides-how-to-validate-polkadot#reference-hardware"
|
||||
"⚠️ The hardware does not meet the minimal requirements {} for role 'Authority' find out more at:\n\
|
||||
https://wiki.polkadot.network/docs/maintain-guides-how-to-validate-polkadot#reference-hardware",
|
||||
err
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user