Bug after upgrading to wrangler 3.28.1

After upgrading wrangler from 3.28.0 -> 3.28.1, I run into this: Error: Cannot find module 'worker/node_modules/miniflare/dist/src/index.js'. Please verify that the package.json has a valid "main" entry Manually checking that folder shows that the dist folder is missing. Upon downgrading to 3.28.0, it properly shows up again. Is this a known issue?
3 Replies
lynn
lynn9mo ago
(also, if this is the wrong place to be asking about this, please let me know where to submit the bug report)
MrBBot
MrBBot9mo ago
Hey! 👋 Thanks for reporting this, could you share the output of npm why miniflare after upgrading? Would you also be able to take a backup of your package lockfile (package-lock.json, yarn.lock, etc), delete it, then rerun the install command?
lynn
lynn9mo ago
for reference, here is my npm why miniflare
➜ worker git:(main) ✗ npm why miniflare
node_modules/miniflare
miniflare@"3.20240129.2" from [email protected]
node_modules/wrangler
dev wrangler@"^3.28.0" from the root project
➜ worker git:(main) ✗ npm why miniflare
node_modules/miniflare
miniflare@"3.20240129.2" from [email protected]
node_modules/wrangler
dev wrangler@"^3.28.0" from the root project
I deleted my package locks & installed the latest 3.28.2 and I'm not getting the issue anymore. I do see that the miniflare dependency was bumped between 3.28.0 -> 3.28.2, so I'm not sure if it was that bump or clearing the old lockfiles that fixed it, but either way it's fixed now. Appreciate the response & thank you 🙏
Want results from more Discord servers?
Add your server