ERROR ENOTDIR: not a directory, stat nuxt-og-image/dist/runtime/mock/proxy-cjs.js/index.js
I started getting this error since today when building cloudflare-pages version of my nuxt 4 application.
I tried rolling back to an already released version of my app but it end's up with the same error.
Happens on npm and pnpm, also tried removing node modules, clearing npm cache etc but with no result.
7 Replies
Hi @Hro. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave:
----------------------
I'm sorry, but the knowledge sources provided do not contain specific information about the error:
when building a Cloudflare Pages version of a Nuxt 4 application. There is no mention of this particular error, nor of issues with the
nuxt-og-image module or its runtime files in the context of Cloudflare Pages or recent changes that could cause this.
You have already tried common troubleshooting steps such as rolling back to a previous version, clearing caches, and reinstalling dependencies, which are generally recommended for similar issues. However, without more targeted information in the knowledge sources, I cannot provide a definitive solution or root cause for this error.
If you continue to experience this issue, I recommend checking for recent updates or issues in the nuxt-og-image repository, or opening a new issue with detailed logs and reproduction steps.
----------------------
Note: you can ask me a follow up question by @ mentioning me again :speech_balloon:
----------------------<@385142776674910238> Kapa.ai is still learning and improving, please let me know how I did by reacting below.
Disabling og image {ogImage: {enabled: false}} allows me to do a build. Any clue?
are you using the latest module version?
it's an issue with unenv v2 and v1 conflict
Hey Harlan thanks for replying. Here's what I have installed:
Looks ok to me?
(pnpm why unenv)
Hm this does look correct
You can try pnpm dedupe
That did nothing (changed nothing in pnpm lockfile nor package json.) I also tried updating wrangler, pinning @unhead/vue@2.0.14 but no luck so far.
Enjoy your holiday! If you feel it's related, we can pick it back up after. Nothing urgent here, perhaps we can later do a screen share.