mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-27 06:57:58 +00:00
Re-add deprecated --execution arg on benchmark pallet (#14567)
* Add DeferGuard::new Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> * Re-add deprecated 'execution' arg to benchmark pallet cmd. Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> * Extend tests Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> * Remove from tests Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io> --------- Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
This commit is contained in:
committed by
GitHub
parent
c4e880c155
commit
ee0be2bab7
@@ -147,6 +147,16 @@ impl PalletCmd {
|
||||
<<<BB as BlockT>::Header as HeaderT>::Number as std::str::FromStr>::Err: std::fmt::Debug,
|
||||
ExtraHostFunctions: sp_wasm_interface::HostFunctions,
|
||||
{
|
||||
let _d = self.execution.as_ref().map(|exec| {
|
||||
// We print the warning at the end, since there is often A LOT of output.
|
||||
sp_core::defer::DeferGuard::new(move || {
|
||||
log::warn!(
|
||||
target: LOG_TARGET,
|
||||
"⚠️ Argument `--execution` is deprecated. Its value of `{exec}` has on effect.",
|
||||
)
|
||||
})
|
||||
});
|
||||
|
||||
if let Some(output_path) = &self.output {
|
||||
if !output_path.is_dir() && output_path.file_name().is_none() {
|
||||
return Err("Output file or path is invalid!".into())
|
||||
|
||||
Reference in New Issue
Block a user