From f35712eefc60d8b06fcd28e8055e0f78ad2a907f Mon Sep 17 00:00:00 2001 From: jake champion Date: Mon, 10 Mar 2025 14:29:06 +0000 Subject: [PATCH] fix: ensure we pass build_data in the calls to the deploys api This ensures that the bundle will have the correct metadata applied to the deployment. previously this metadata would only get applied for CLI deployments that included the `--build` flag (unless the `--skip-functions-cache` flag was also applied) --- src/utils/deploy/hash-fns.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/utils/deploy/hash-fns.ts b/src/utils/deploy/hash-fns.ts index 69b501b91df..348b7e67458 100644 --- a/src/utils/deploy/hash-fns.ts +++ b/src/utils/deploy/hash-fns.ts @@ -157,6 +157,16 @@ const hashFns = async ( statusCb, tmpDir, }) + + for (const func of functionZips) { + if (!func.buildData) { + func.buildData = { + bootstrapVersion: func.bootstrapVersion, + runtimeAPIVersion: func.runtimeAPIVersion, + } + } + } + const fileObjs = functionZips.map( ({ buildData,