You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi. I'm using this action to upload a project that's not at root an npm project. The output is kind of confusing, and leaves a mess of the workspace.
/usr/local/bin/npx --no-install wrangler --version
npm error npx canceled due to missing packages and no YES option: ["[email protected]"]
npm error A complete log of this run can be found in: /home/runner/.npm/_logs/2024-08-28T17_12_25_179Z-debug-0.log
⚠️ Wrangler not found or version is incompatible. Installing...
📥 Installing Wrangler
/usr/local/bin/npm i [email protected]
okay. Why did you do npm i instead of just npx [email protected] ? Doesn't make sense.
Then when it goes to run:
/usr/local/bin/npx wrangler pages deploy ./_site --project-name=cldr
▲ [WARNING] Warning: Your working directory is a git repo and has uncommitted changes
To silence this warning, pass in --commit-dirty=true
Well, yeah, you dirtied it, wrangler :)
Run git status
HEAD detached at pull/3989/merge
Untracked files:
(use "git add <file>..." to include in what will be committed)
node_modules/
package-lock.json
package.json
So wrangler-action has added a node_modules, package.json and package-lock.json in my work area. And then complains that my work area is a mess.
I'm going to try a preemptive npm i -g [email protected] to see if it cleans things up.
The text was updated successfully, but these errors were encountered:
srl295
added a commit
to unicode-org/cldr
that referenced
this issue
Aug 28, 2024
I agree, this is odd behavior. I'm also now realizing that if we stop running npm i wrangler, we may break users who did not add a step to their GHA workflow to separately install dependencies.
There's two things we should do here:
Only use npx instead of installing wrangler, causing the mess described here.
In v4, do a possibly breaking change where we always use npx (or equivalent) rather than installing wrangler in the local project (or alternatively install globally, but the former probably makes more sense.)
Hi. I'm using this action to upload a project that's not at root an npm project. The output is kind of confusing, and leaves a mess of the workspace.
okay. Why did you do
npm i
instead of justnpx [email protected]
? Doesn't make sense.Then when it goes to run:
Well, yeah, you dirtied it, wrangler :)
So wrangler-action has added a node_modules, package.json and package-lock.json in my work area. And then complains that my work area is a mess.
I'm going to try a preemptive
npm i -g [email protected]
to see if it cleans things up.The text was updated successfully, but these errors were encountered: