From 530162b4c4ad2209e1d4b471036776d70c1ade99 Mon Sep 17 00:00:00 2001 From: Ian Manske Date: Wed, 24 Apr 2024 23:05:24 +0000 Subject: [PATCH] Lazy record deprecation (#12656) # Description In this week's nushell meeting, we decided to go ahead with #12622 and remove lazy records in 0.94.0. For 0.93.0, we will only deprecate `lazy make`, and so this PR makes `lazy make` print a deprecation warning. # User-Facing Changes None, besides the deprecation warning. # After Submitting Remove lazy records. --- crates/nu-cmd-lang/src/core_commands/lazy_make.rs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/crates/nu-cmd-lang/src/core_commands/lazy_make.rs b/crates/nu-cmd-lang/src/core_commands/lazy_make.rs index 20e7308397..7c90a04b78 100644 --- a/crates/nu-cmd-lang/src/core_commands/lazy_make.rs +++ b/crates/nu-cmd-lang/src/core_commands/lazy_make.rs @@ -54,6 +54,18 @@ impl Command for LazyMake { call: &Call, _input: PipelineData, ) -> Result { + nu_protocol::report_error_new( + engine_state, + &ShellError::GenericError { + error: "Deprecated command".into(), + msg: "warning: lazy records and the `lazy make` command will be removed in 0.94.0" + .into(), + span: Some(call.head), + help: None, + inner: vec![], + }, + ); + let span = call.head; let columns: Vec> = call .get_flag(engine_state, stack, "columns")?