From abe562552327d9f40dcb07c65741ec968a914369 Mon Sep 17 00:00:00 2001 From: Rene Buchmayer Date: Thu, 23 May 2024 15:02:44 +0200 Subject: [PATCH] fix: Make `tracing` JSON field optional --- lambda-extension/src/events.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lambda-extension/src/events.rs b/lambda-extension/src/events.rs index c61fc9f0..db872d96 100644 --- a/lambda-extension/src/events.rs +++ b/lambda-extension/src/events.rs @@ -1,7 +1,7 @@ use serde::Deserialize; /// Request tracing information -#[derive(Debug, Deserialize)] +#[derive(Debug, Default, Deserialize)] #[serde(rename_all = "camelCase")] pub struct Tracing { /// The type of tracing exposed to the extension @@ -20,6 +20,7 @@ pub struct InvokeEvent { /// The function's Amazon Resource Name pub invoked_function_arn: String, /// The request tracing information + #[serde(default)] pub tracing: Tracing, }