website-v2 icon indicating copy to clipboard operation
website-v2 copied to clipboard

Context conflict from nuxt generate

Open oyedejioyewole opened this issue 4 years ago • 7 comments

Using windows 10

Steps to reproduce:

  1. yarn
  2. yarn build (works the first time)
  3. yarn build (Context conflict)

It doesn't build instead I get Context conflict.

oyedejioyewole avatar Jan 02 '22 10:01 oyedejioyewole

@danielroe

smarroufin avatar Jan 04 '22 12:01 smarroufin

@OyewoleOyedeji Is this something you're experiencing with the nuxt/nuxtjs.org repository, or is this a more general issue you're facing?

danielroe avatar Jan 04 '22 15:01 danielroe

Only with this repository

oyedejioyewole avatar Jan 04 '22 15:01 oyedejioyewole

My bad, I thought this was about a general issue.

Actually, I reproduced it on my Mac. As you said, 2 yarn build in a row.

yarn run v1.22.10
$ nuxt generate
ℹ [email protected] running with config: windi.config.js                                                                                                                                         nuxt:windicss 10:56:37
✔ Skipping webpack build as no changes detected                                                                                                                                                             10:56:38

 FATAL  Context conflict                                                                                                                                                                                    10:56:38

  at checkConflict (node_modules/@docus/theme/node_modules/unctx/dist/index.js:10:13)
  at Object.call (node_modules/@docus/theme/node_modules/unctx/dist/index.js:27:7)
  at ModuleContainer.wrappedModule (node_modules/@nuxt/kit/dist/index.js:950:21)
  at ModuleContainer.addModule (node_modules/@nuxt/core-edge/dist/core.js:174:34)
  at node_modules/@nuxt/utils-edge/dist/utils.js:496:61
  at async ModuleContainer.ready (node_modules/@nuxt/core-edge/dist/core.js:45:7)
  at async Nuxt._init (node_modules/@nuxt/core-edge/dist/core.js:346:5)


   ╭─────────────────────────────╮
   │                             │
   │   ✖ Nuxt Fatal Error        │
   │                             │
   │   Error: Context conflict   │
   │                             │
   ╰─────────────────────────────╯

error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

@danielroe This reminds me it already happened to me to have some deploys (of nuxtjs.org) failing due to this kind of blurry error (Context conflict) and my only solution was to "Clear cache and redeploy".

smarroufin avatar Jan 05 '22 10:01 smarroufin

@smarroufin where can I find the build cache

oyedejioyewole avatar Jan 05 '22 15:01 oyedejioyewole

@OyewoleOyedeji I would suggest rm -rf node_modules ; yarn ; yarn build as workaround for now, it does the trick. It might be caused by docus node_modules cache :shrug: not sure what is going on

smarroufin avatar Jan 05 '22 15:01 smarroufin

Thanks

oyedejioyewole avatar Jan 05 '22 16:01 oyedejioyewole