generator-jhipster: webpack is not recompiling project on change
Overview of the issue
I faced this problem several times and only workaround I found so far is to create a new project from scratch. Somehow, after a while, live reload feature for dev environment is not working. I had to run yarn start for any change.
I don’t know what breaks live-reload, if you can guide me I can troubleshoot… I don’t know where to check…
Motivation for or Use Case
Reproduce the error
Related issues
Suggest a Fix
JHipster Version(s)
JHipster Generator v4.5.6
Browsers and Operating System
OS
LSB Version: core-9.20160110ubuntu0.2-amd64:core-9.20160110ubuntu0.2-noarch:printing-9.20160110ubuntu0.2-amd64:printing-9.20160110ubuntu0.2-noarch:security-9.20160110ubuntu0.2-amd64:security-9.20160110ubuntu0.2-noarch
Distributor ID: Ubuntu
Description: Ubuntu 16.04.2 LTS
Release: 16.04
Codename: xenial
Browser
google chrome
Version 58.0.3029.81 (64-bit)
JHipster configuration
Executing jhipster:info Welcome to the JHipster Information Sub-Generator
JHipster Version(s)
/home/infoowl/git/xxxx
└── (empty)
cat: no such file or directory: .yo-rc.json
JHipster configuration, a .yo-rc.json file generated in the root folder
Entity configuration(s) entityName.json files generated in the .jhipster directory
ls: no such file or directory: .jhipster/*.json
Browsers and Operating System
java version “1.8.0_121” Java™ SE Runtime Environment (build 1.8.0_121-b13) Java HotSpot™ 64-Bit Server VM (build 25.121-b13, mixed mode)
git version 2.7.4
node: v7.10.0
npm: 4.2.0
bower: 1.8.0
gulp: [12:52:48] CLI version 3.9.1
yeoman: 1.8.5
yarn: 0.24.5
Docker version 17.03.1-ce, build c6d412e
docker-compose version 1.13.0, build 1719ceb
Execution complete
- Checking this box is mandatory (this is just to show you read everything)
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 26 (15 by maintainers)
@deepu105 I think I found the problem,
I added this watchOptions to webpack configuration, it fixes the problem. I think webpack tries to watch lots of files and couldn’t manage it… If you think this is a fix I will be glad to pr…
I encounter the same issue, when using jhipster-registry project. Ping @PierreBesson as you have the same in your computer 😉
I use the fix
watchOptions, suggested by @ygokirmak inwebpack.dev.jsfile, and it works!!So I’m pretty sure we should add this to our config, as it is safe to ignore
/node_modules/@ygokirmak I have same problem, i use this command resolve it.:
sudo yarn start,I think it’s node’s permission problem.thats strange I didnt think it was watching node_modules. So please PR
Thanks @ygokirmak - I’m really eager to test this!
If we are indeed watching node_modules, then that’s a great enhancement to our current configuration!!