Skip to content

[BUG]: Typo in dwrangler.ts causes WRANGLER_INJECT_MODE to always fallback to inline #241

Description

@mshibanami

dmno version

0.0.41

Steps to reproduce

  1. Configure WRANGLER_INJECT_MODE: { value: 'secrets' } in your DMNO schema.
  2. Set a config item to dynamic: true.
  3. Run dwrangler dev.

What is expected?

dwrangler should recognize the secrets injection mode and pass dynamic variables to wrangler using --var flags.

What is actually happening?

dwrangler silently falls back to inline mode. Dynamic variables are not injected as secrets. This happens because DmnoWranglerEnvSchema defines WRANGLER_INJECT_MODE, but dwrangler.ts mistakenly checks for DWRANGLER_INJECT_MODE.

System Info

Any additional comments?

The typo is located in dwrangler.ts:

const injectMode: 'inline' | 'secrets' = dmnoWranglerSettings.DWRANGLER_INJECT_MODE as any || 'inline';

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions