From ab67e0dc192c0c1062fff4380c9d6fad16ac8aec Mon Sep 17 00:00:00 2001 From: Edmund Hung Date: Wed, 27 Nov 2024 11:52:00 +0000 Subject: [PATCH] make experimental flag explicit --- packages/wrangler/src/api/dev.ts | 1 + packages/wrangler/src/api/integrations/platform/index.ts | 1 + packages/wrangler/src/deploy/index.ts | 3 ++- packages/wrangler/src/dev.ts | 1 + packages/wrangler/src/experimental-flags.ts | 4 ++-- 5 files changed, 7 insertions(+), 3 deletions(-) diff --git a/packages/wrangler/src/api/dev.ts b/packages/wrangler/src/api/dev.ts index 7da6d6642443..b217a953c173 100644 --- a/packages/wrangler/src/api/dev.ts +++ b/packages/wrangler/src/api/dev.ts @@ -229,6 +229,7 @@ export async function unstable_dev( const devServer = await run( { FILE_BASED_REGISTRY: fileBasedRegistry, + RESOURCES_PROVISION: false, }, () => startDev(devOptions) ); diff --git a/packages/wrangler/src/api/integrations/platform/index.ts b/packages/wrangler/src/api/integrations/platform/index.ts index 685b6bfa9627..59d55c880e4d 100644 --- a/packages/wrangler/src/api/integrations/platform/index.ts +++ b/packages/wrangler/src/api/integrations/platform/index.ts @@ -103,6 +103,7 @@ export async function getPlatformProxy< const miniflareOptions = await run( { FILE_BASED_REGISTRY: Boolean(options.experimentalRegistry ?? true), + RESOURCES_PROVISION: false, }, () => getMiniflareOptionsFromConfig(rawConfig, env, options) ); diff --git a/packages/wrangler/src/deploy/index.ts b/packages/wrangler/src/deploy/index.ts index ea37806ecc51..11e1b4a5933f 100644 --- a/packages/wrangler/src/deploy/index.ts +++ b/packages/wrangler/src/deploy/index.ts @@ -237,7 +237,8 @@ export type DeployArgs = StrictYargsOptionsToInterface; export async function deployHandler(args: DeployArgs) { await run( { - RESOURCES_PROVISION: args.experimentalProvision, + FILE_BASED_REGISTRY: false, + RESOURCES_PROVISION: args.experimentalProvision ?? false, }, () => deployWorker(args) ); diff --git a/packages/wrangler/src/dev.ts b/packages/wrangler/src/dev.ts index dc8d5e75595e..e44c83052d9f 100644 --- a/packages/wrangler/src/dev.ts +++ b/packages/wrangler/src/dev.ts @@ -368,6 +368,7 @@ const command = defineCommand({ const devInstance = await run( { FILE_BASED_REGISTRY: args.experimentalRegistry, + RESOURCES_PROVISION: false, }, () => startDev(args) ); diff --git a/packages/wrangler/src/experimental-flags.ts b/packages/wrangler/src/experimental-flags.ts index 4fffee043c08..2dddf7f304db 100644 --- a/packages/wrangler/src/experimental-flags.ts +++ b/packages/wrangler/src/experimental-flags.ts @@ -2,8 +2,8 @@ import { AsyncLocalStorage } from "async_hooks"; import { logger } from "./logger"; type ExperimentalFlags = { - FILE_BASED_REGISTRY?: boolean; - RESOURCES_PROVISION?: boolean; + FILE_BASED_REGISTRY: boolean; + RESOURCES_PROVISION: boolean; }; const flags = new AsyncLocalStorage();