Skip to content

Commit

Permalink
make experimental flag explicit
Browse files Browse the repository at this point in the history
  • Loading branch information
edmundhung committed Nov 27, 2024
1 parent 4169463 commit ab67e0d
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 3 deletions.
1 change: 1 addition & 0 deletions packages/wrangler/src/api/dev.ts
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,7 @@ export async function unstable_dev(
const devServer = await run(
{
FILE_BASED_REGISTRY: fileBasedRegistry,
RESOURCES_PROVISION: false,
},
() => startDev(devOptions)
);
Expand Down
1 change: 1 addition & 0 deletions packages/wrangler/src/api/integrations/platform/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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)
);
Expand Down
3 changes: 2 additions & 1 deletion packages/wrangler/src/deploy/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,8 @@ export type DeployArgs = StrictYargsOptionsToInterface<typeof deployOptions>;
export async function deployHandler(args: DeployArgs) {
await run(
{
RESOURCES_PROVISION: args.experimentalProvision,
FILE_BASED_REGISTRY: false,
RESOURCES_PROVISION: args.experimentalProvision ?? false,
},
() => deployWorker(args)
);
Expand Down
1 change: 1 addition & 0 deletions packages/wrangler/src/dev.ts
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,7 @@ const command = defineCommand({
const devInstance = await run(
{
FILE_BASED_REGISTRY: args.experimentalRegistry,
RESOURCES_PROVISION: false,
},
() => startDev(args)
);
Expand Down
4 changes: 2 additions & 2 deletions packages/wrangler/src/experimental-flags.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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<ExperimentalFlags>();
Expand Down

0 comments on commit ab67e0d

Please sign in to comment.