workers-sdk: 🐛 BUG: pages publish very slow / crashing
What version of Wrangler are you using?
2.0.8
What operating system are you using?
Mac
Describe the Bug
I’m trying to upload my site, it’s about 300MB, it uploads to KV fine with wrangler 1
When I upload to pages with wrangler 2 it goes reaaallly slow and then crashes
▲ [WARNING] Warning: Your working directory is a git repo and has uncommitted changes
To silence this warning, pass in --commit-dirty=true
🌍 Uploading... (809/8009)
/usr/local/lib/node_modules/wrangler/wrangler-dist/cli.js:16264
throw ex;
^
FatalError: Failed to upload files. Please try again.
at /usr/local/lib/node_modules/wrangler/wrangler-dist/cli.js:123689:31
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async run2 (/usr/local/lib/node_modules/wrangler/wrangler-dist/cli.js:122127:26) {
code: 1
}
I posted it on discord https://discord.com/channels/595317990191398933/799437470004412476/983442112534175815
If I try to upload it via web it errors telling me not to upload more than 1000 files. If I zip it it says the zip is too big. I don’t see a way to upload a zip file with the CLI. No idea how to get my files into Pages.
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Reactions: 2
- Comments: 29 (15 by maintainers)
Hey there! Sorry to hear this. What you’re describing with the dashboard is expected (we’ll be bumping that up soon).
What you’re seeing with wrangler however is a bug. Our hypothesis is that your auth token is expiring during the upload because of low upload bandwidth? I’ve opened a PR with a fix for this.
Can you try this version of wrangler and let us know if it helps?
npx https://prerelease-registry.developers.workers.dev/runs/2455435541/npm-package-wrangler-1199 dev path/to/script.jsCheers.
I’m running into this same issue with
wrangler pages deploy, on a large directory (6k+ files) with several large files (0.5MB max file size). Not sure if any of this information helps, but here’s what I’m seeing:Wrangler version is 3.22.4. I’ve retried several times, and it always fails after ~15 minutes of trying to upload the files.
Ah, okay, thanks for that additional info! Absolutely feel free to put up whatever you have right now and we can help get it over the line 😊
Thank you for actively working on this.
Interesting. Thank you for testing this. In that case, my hypothesis was incorrect. I’ll ship that anyway since it’s an improvement.
I’ll add some verbose debug logs and ship a version for you’ll so we can get some more info on what’s up. Cheers.
@sidharthachatterjee I have tested this a couple times, I am having no issues when running the
devcommand you provided, but still am not seeing any improvements when trying to run thepages publishcommand. It still hangs and then throws the same error as above.