From 24002880c959c3eefde96bd6915dc36d5f502c0f Mon Sep 17 00:00:00 2001 From: Harutaka Kawamura Date: Thu, 24 Aug 2023 21:54:07 +0900 Subject: [PATCH] Apply suggestions from code review Co-authored-by: Dhruv Manilawala --- crates/ruff/src/jupyter/schema.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/crates/ruff/src/jupyter/schema.rs b/crates/ruff/src/jupyter/schema.rs index 17b03e474a312..18f4d3428f711 100644 --- a/crates/ruff/src/jupyter/schema.rs +++ b/crates/ruff/src/jupyter/schema.rs @@ -120,7 +120,6 @@ pub struct RawCell { /// 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 /// - #[serde(skip_serializing_if = "Option::is_none")] pub id: Option, /// Cell-level metadata. pub metadata: Value, @@ -136,7 +135,6 @@ pub struct MarkdownCell { /// 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 /// - #[serde(skip_serializing_if = "Option::is_none")] pub id: Option, /// Cell-level metadata. pub metadata: Value, @@ -152,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 /// - #[serde(skip_serializing_if = "Option::is_none")] + #[serialize_always] pub id: Option, /// Cell-level metadata. pub metadata: Value,