Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using watch fail on first refresh #91

Open
lucabecchetti opened this issue Jan 21, 2021 · 1 comment
Open

Using watch fail on first refresh #91

lucabecchetti opened this issue Jan 21, 2021 · 1 comment
Labels
bug Something isn't working

Comments

@lucabecchetti
Copy link

Hi guys, I have a test with some typescript mixins, if I run test, all works!

BaseField.vue Component
✓ Is in wrapper element
✓ Has slot
✓ It contains a valid button-group
✓ It contains a valid button-group label
✓ It not contains a default required *
✓ It contains a default required *
✓ Is visible by default
✓ Can toggle visibility
✓ Is does not show any errors
✓ Is show errors when triggered

But, if I run test with --watch options, first time all works, but at the first watcher refresh I get:

TS2307: Cannot find module '!../../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js' or its corresponding type declarations.

For each .ts file that it tries to load!

@lucabecchetti lucabecchetti added the bug Something isn't working label Jan 21, 2021
@lingo
Copy link

lingo commented Feb 10, 2022

I get this also.

First time runs fine, but with warnings:

  [                         ] 0% () WEBPACK  Compiling...                                                         
                                                                                                                  
  [=========================] 99% (done) WEBPACK  Compiled with 8 warning(s)                                      
                                                                                                                  
Warning in ./node_modules/@babel/core/lib/config/files/configuration.js                                           
                                                                                                                  
  Critical dependency: require function is used in a way in which dependencies cannot be statically extracted     
                                                                                                                  
Warning in ./node_modules/@babel/core/lib/config/files/import.js                                                  
                                                                                                                  
  Critical dependency: the request of a dependency is an expression                                               
                                                                                                                  
Warning in ./node_modules/@babel/core/lib/config/files/module-types.js                                            
                                                                                                                  
  Critical dependency: the request of a dependency is an expression                                               
                                                                                                                  
Warning in ./node_modules/@babel/core/lib/config/files/plugins.js                                                 
                                                                                                                  
  Critical dependency: require function is used in a way in which dependencies cannot be statically extracted     
                                                                                                                  
Warning in ./node_modules/@babel/core/lib/config/files/plugins.js                                                 
                                                                                                                  
  Critical dependency: require function is used in a way in which dependencies cannot be statically extracted     
                                                                                                                  
Warning in ./node_modules/@babel/core/lib/config/files/plugins.js                                                 
                                                                                                                  
  Critical dependency: require function is used in a way in which dependencies cannot be statically extracted     
                                                                                                                  
Warning in ./node_modules/@babel/core/lib/config/files/plugins.js                                                 
                                                                                                                  
  Critical dependency: require function is used in a way in which dependencies cannot be statically extracted     
                                                                                                                  
Warning                                                                                                           
                                                                                                                  
  configuration                                                                                                   
  The 'mode' option has not been set, webpack will fallback to 'production' for this value.                       
  Set 'mode' option to 'development' or 'production' to enable defaults for each environment.                     
  You can also set it to 'none' to disable any default behavior. Learn more: https://webpack.js.org/configuration/
mode/                                                                                                             

When a file is modified (i.e. the second run) the following appears.

  [                         ] 0% () WEBPACK  Compiling...

  [=========================] 99% (done) WEBPACK  Compiled with 8 warning(s)

Warning in ./node_modules/@babel/core/lib/config/files/configuration.js

  Critical dependency: require function is used in a way in which dependencies cannot be statically extracted

Warning in ./node_modules/@babel/core/lib/config/files/import.js

  Critical dependency: the request of a dependency is an expression

Warning in ./node_modules/@babel/core/lib/config/files/module-types.js

  Critical dependency: the request of a dependency is an expression

Warning in ./node_modules/@babel/core/lib/config/files/plugins.js

  Critical dependency: require function is used in a way in which dependencies cannot be statically extracted

Warning in ./node_modules/@babel/core/lib/config/files/plugins.js

  Critical dependency: require function is used in a way in which dependencies cannot be statically extracted

Warning in ./node_modules/@babel/core/lib/config/files/plugins.js

  Critical dependency: require function is used in a way in which dependencies cannot be statically extracted

Warning in ./node_modules/@babel/core/lib/config/files/plugins.js

  Critical dependency: require function is used in a way in which dependencies cannot be statically extracted

Warning 

  configuration
  The 'mode' option has not been set, webpack will fallback to 'production' for this value.
  Set 'mode' option to 'development' or 'production' to enable defaults for each environment.
  You can also set it to 'none' to disable any default behavior. Learn more: https://webpack.js.org/configuration/mode/

 MOCHA  Testing...

 RUNTIME EXCEPTION  Exception occurred while loading your tests

Error: /home/user/project/babel.config.js: Error while loading config - Cannot find module '/home/user/project/babel.config.js'
    at webpackEmptyContext (/home/user/project/dist/main.js:2318:10)
    at loadCjsDefault (/home/user/project/dist/main.js:1925:42)
    at loadCjsOrMjsDefault (/home/user/project/dist/main.js:1897:16)
    at loadCjsOrMjsDefault.next (<anonymous>)
    at readConfigJS (/home/user/project/dist/main.js:1587:47)
    at readConfigJS.next (<anonymous>)
    at Function.<anonymous> (/home/user/project/dist/main.js:4268:3)
    at Generator.next (<anonymous>)
    at evaluateSync (/home/user/project/node_modules/gensync/index.js:251:28)
    at Function.sync (/home/user/project/node_modules/gensync/index.js:89:14)
    at sync (/home/user/project/dist/main.js:4311:25)
    at sync (/home/user/project/node_modules/gensync/index.js:182:19)
    at onFirstPause (/home/user/project/node_modules/gensync/index.js:210:24)
    at Generator.next (<anonymous>)
    at cachedFunction (/home/user/project/dist/main.js:292:46)
    at cachedFunction.next (<anonymous>)

  [=========================] 100% (completed)

mocha 8.4.0
webpack 5.41.1
webpack-cli 4.7.2
mochapack 2.1.4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants