Skip to content

cannot use wranglerVersion to use latest v4 release #390

@dotysan

Description

@dotysan

It crashes in uploadSecrets()

if (semverCompare(config["WRANGLER_VERSION"], "3.4.0")) {
return legacyUploadSecrets(
config,
packageManager,
secrets,
environment,
workingDirectory,
);
}
let args = ["wrangler", "secret", "bulk"];
// if we're on a WRANGLER_VERSION prior to 3.60.0 use wrangler secret:bulk
if (semverLt(config["WRANGLER_VERSION"], "3.60.0")) {
args = ["wrangler", "secret:bulk"];
}
with Error: Invalid Version: which appears to be a bug.

These all fail:

wranglerVersion: 4
wranglerVersion: v4
wranglerVersion: 4.*
wranglerVersion: 4.x
wranglerVersion: 4.*.*

We don't want to hard-code the full version. Nor do we want "latest" as that might bump to v5 someday. We only want the latest v4.

Workaround was to avoid b0rk wranglerVersion and add this step before cloudflare/wrangler-action.

      - name: Install Wrangler v4
        run: npm install --save-dev wrangler@4

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions