Skip to content

Watchpack Error (initial scan): Error: ENOTDIR: not a directory, scandir #226

Closed

Description

@productdevbook

https://github.com/productfrontenddeveloper/nuxt3_bug

Environment



Describe the bug and expected behavior

CleanShot 2021-10-12 at 19 52 58@2x

Steps to

yarn install
yarn dev

Activity

  1. pi0 commented on Oct 12, 2021

    @pi0
    Member
  2. danielroe commented on Oct 12, 2021

    @danielroe
    Member

    @productfrontenddeveloper You had issues with two libraries, date-fns and vue-filepond.

    Issues:

    • vue-filepond was importing from vue/dist/vue.esm which conflicted with a vue alias provided by bridge
    • date-fns resolution issue probably needs to be addressed in @nuxtjs/date-fns module as it's a byproduct of the wp5 resolver we've backported...
  3. productdevbook commented on Oct 12, 2021

    @productdevbook
    MemberAuthor

    @danielroe thank you, fixed vue-filepond but @nuxtjs/date-fns problem some.
    iam update my repo.

  4. jodelamo commented on Jan 28, 2022

    @jodelamo

    Hey everyone. Very excited to upgrade our web application to Nuxt 3, but this one's still a blocker for us. Any work being done on @nuxtjs/date-fns to resolve the above mentioned issues?

    If not, any pointers on what we could do to help out?

    EDIT: Somehow overlooked that this was closed. If so, what's the solution?

  5. zulvkr commented on Feb 2, 2022

    @zulvkr

    Hi, @productdevbook, I know this is old. Care to share your solution for vue-filepond? I thought I will use filepond core instead if I can't make it work.

  6. FieldMarshallVague commented on Mar 23, 2022

    @FieldMarshallVague

    I am having the same trouble with Nuxt-Bridge. It seems to have started since I tried switching from Webpack to Vite, but I've switched back and am still having the same problem.

    ✖ Server
      Compiled with some errors in 233.15ms
    
    i Preparing project for development                                                                                                                                                                                                                                12:52:30
    i Initial build may take a while                                                                                                                                                                                                                                   12:52:30
    
     WARN  Components directory not found: ~/components/base/foo                                                                                                                                                                                                       12:52:30
    
    i Discovered Components: .nuxt/components/readme.md                                                                                                                                                                                                                12:52:30
    √ Builder initialized                                                                                                                                                                                                                                              12:52:30
    
    ✖ Client
      Compiled with some errors in 264.67ms
    
    ● Server █████████████████████████ building (10%) 1/1 modules 0 active
    
    
    
     ERROR  Watchpack Error (initial scan): Error: ENOTDIR: not a directory, scandir 'C:\projects\test\.nuxt\server.js'                                                                                                                        12:52:30
    
    √ Nuxt files generated                                                                                                                                                                                                                                             12:52:30
    
     ERROR  Failed to compile with 1 errors                                                                                                                                                                                                            friendly-errors 12:52:30
    
    This dependency was not found:                                                                                                                                                                                                                     friendly-errors 12:52:30
                                                                                                                                                                                                                                                       friendly-errors 12:52:30
    * C:\projects\test\.nuxt\client.js in multi ./node_modules/eventsource-polyfill/dist/browserify-eventsource.js (webpack)-hot-middleware/client.js?reload=true&timeout=30000&ansiColors=&overlayStyles=&path=%2F__webpack_hmr%2Fclient&name=client ./.nuxt/client.js
                                                                                                                                                                                                                                                       friendly-errors 12:52:30
    To install it, you can run: npm install --save C:\projects\test\.nuxt\client.js                                                                                                                                            friendly-errors 12:52:31
    
     ERROR  Watchpack Error (initial scan): Error: ENOTDIR: not a directory, scandir 'C:\projects\test\.nuxt\client.js'                                                                                                                        12:52:31
    
    
    ● Client █████████████████████████ building (12%) 18/19 modules 1 active
     babel-loader › .nuxt\client.js
    
    ✖ Server
      Compiled with some errors in 16.18ms
    
    

    It hangs at this point, without returning to prompt. I've updated all the packages to latest, but this didn't help.

    I'm using target: static with nitro and SSR: true.

    I'm wondering what is the easiest way to start over? Or even if that will help? I've deleted .nuxt and output folders (tried generate, too, but that just quits at the same point without showing any errors).

    NOTE: I had a previous error, where it was complaining about not finding 'nuxt/ui-templates', which I fixed from another issue on this repo (mapping the ui-templates to ui-templates-edge in the package.json).

    {
      "name": "example.com",
      "version": "1.0.0",
      "private": true,
      "scripts": {
        "dev": "nuxi dev",
        "build": "nuxi build",
        "start": "nuxi preview",
        "clean": "nuxi clean",
        "generate": "nuxi generate",
        "lint:js": "eslint --ext \".js,.vue\" --ignore-path .gitignore .",
        "lint": "npm run lint:js",
        "test": "jest"
      },
      "dependencies": {
        "@nuxt/ui-templates": "npm:@nuxt/[email protected]",
        "@nuxtjs/applicationinsights": "^1.2.2",
        "@nuxtjs/axios": "^5.13.6",
        "@nuxtjs/gtm": "^2.4.0",
        "@nuxtjs/strapi": "^1.3.1",
        "@vueuse/head": "^0.7.5",
        "core-js": "^3.21.1",
        "graphql": "^16.3.0",
        "graphql-tag": "^2.12.6",
        "nuxt-edge": "latest",
        "vue-router": "^4.0.14",
        "vue-use-popperjs": "^2.3.1"
      },
      "devDependencies": {
        "@babel/eslint-parser": "^7.17.0",
        "@babel/plugin-proposal-optional-chaining": "^7.16.7",
        "@babel/plugin-syntax-nullish-coalescing-operator": "^7.8.3",
        "@nuxt/bridge": "npm:@nuxt/bridge-edge@^3.0.0-27467056.93c4dfe",
        "@nuxt/kit": "npm:@nuxt/kit-edge@^3.0.0-27467056.93c4dfe",
        "@nuxt/types": "^2.15.8",
        "@nuxtjs/eslint-config-typescript": "^9.0.0",
        "@nuxtjs/eslint-module": "^3.0.2",
        "@nuxtjs/google-fonts": "^1.3.0",
        "@nuxtjs/style-resources": "^1.2.1",
        "@nuxtjs/svg": "^0.4.0",
        "@vue/runtime-dom": "^3.2.31",
        "@vue/test-utils": "^1.3.0",
        "babel-core": "7.0.0-bridge.0",
        "babel-jest": "^27.5.1",
        "eslint": "^8.11.0",
        "eslint-config-prettier": "^8.5.0",
        "eslint-plugin-nuxt": "^3.2.0",
        "eslint-plugin-vue": "^8.5.0",
        "fibers": "^5.0.1",
        "hookable": "^5.1.1",
        "jest": "^27.5.1",
        "postcss-preset-env": "^7.4.3",
        "prettier": "^2.6.0",
        "sass": "^1.49.9",
        "sass-loader": "^12.6.0",
        "ts-jest": "^27.1.3",
        "typescript": "4.6.2",
        "vite-plugin-checker": "^0.4.3",
        "vue-jest": "^3.0.7",
        "vue-template-babel-compiler": "^1.1.3",
        "vue-tsc": "^0.33.7"
      }
    }
    
    

    Any thoughts or advice would be appreciated.

  7. transferred this issue fromnuxt/frameworkon Apr 13, 2022
  8. kota-nakagawa commented on Jun 23, 2022

    @kota-nakagawa

    スクリーンショット 2022-06-24 1 16 43

    I'm useing @nuxt/date-fns.

    Please let me know if you intend to correct the error here.
    This error also occurs in the latest version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bridgebugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions