From 8a031c40aec4a9987ae68897731c1d199f9fa8e5 Mon Sep 17 00:00:00 2001 From: Dhruv Manilawala Date: Thu, 24 Aug 2023 18:39:10 +0530 Subject: [PATCH] Revert to using `skip_serializing_if` --- crates/ruff/src/jupyter/schema.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/ruff/src/jupyter/schema.rs b/crates/ruff/src/jupyter/schema.rs index 18f4d3428f711..e466615feca52 100644 --- a/crates/ruff/src/jupyter/schema.rs +++ b/crates/ruff/src/jupyter/schema.rs @@ -150,7 +150,7 @@ pub struct CodeCell { /// Technically, id isn't required (it's not even present) in schema v4.0 through v4.4, but /// it's required in v4.5. Main issue is that pycharm creates notebooks without an id /// - #[serialize_always] + #[serde(skip_serializing_if = "Option::is_none")] pub id: Option, /// Cell-level metadata. pub metadata: Value,