-
Notifications
You must be signed in to change notification settings - Fork 12k
ng serve doesn't re-render files most of the time #5117
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
Comments
Noticed it here too. |
The same issue I encountered since I updated to 1.0.0-rc.0 |
Hi, same here I've installed everything today and after the first launch (with ng serve), every change is listened and the page is rebooted but the changes to the TS are not updated (the TS is not compiled or something) I've to kill the liveserver and start it again for every change OS?Windows 10 Versions.@angular/cli: 1.0.0-rc.0 |
Hi, i have the same issue, but it worked 2 Days ago with the 1.0.0-beta.32 Version. OS: Version: |
@Momotanien Did you have a different version 2 days ago? |
@mp-tbianchi Ups, sorry forgot to mention it. I updated my entry. |
I had the same issue with rc.0. |
I believe this may be fixed by a pending PR: #5164 |
Hi |
Is @angular/cli: 1.0.0-rc.1 released? I can't find it under https://github.com/angular/angular-cli/releases. |
Maybe he meant this commit : |
Sorry |
I can't reproduce this in a brand new project. Can you give me exact repro steps? e.g. the project where this happens (a new project for instance, all commands you run to see this, the exact file you change. |
#5137 might be related, but it happens exclusively with |
I had the same issue with I create a brand new project with OSWindows 7 x64 Version@angular/cli : 1.0.0-rc.1 |
@ovalol I really need exact reproduction steps, otherwise there isn't much I can do but wait for it to happen randomly. |
Hi |
@filipesilva here steps to reproduce Steps
|
Hey, I just tried creating a new project too.
Console says |
One thing to add |
@ovalol I tried following your steps exactly as you posted, looking at the changes in the browser, and I could always see the correct output (first @mp-tbianchi I tried your changes as well, and could see @mfreirehfexp I haven't seen that behaviour yet but will keep an eye out for it. I noticed that you three are using Windows (7 and 10). I am using Windows as well and can't see this... maybe there's something else at play. Are you using a symlink or a juntion on your project path? Is there anything else odd you've seen? Do you get |
@filipesilva I don't have any symlink or junctions in the path. I've had the bug on "old" projects that have been updated to the latest angular/cli and also new projects (in the example above). Both projects are in separate folders. |
@filipesilva I m not using symlink or anything else. Everything works fine with the previous version |
Oh, I just noticed something very weird. What IDE/Editor do you all use? When I use webstorm to modify the file : if I save with CTRL+S, sometimes the change is seen, sometimes not (I track this by checking if [rendered] is present on the But if I modify the file with Notepad++ and save with CTRL+S, the [rendered] appears everytime. |
@mp-tbianchi I also use Webstorm |
I use webstorm to. |
https://webpack.github.io/docs/troubleshooting.html#file-saves-in-webstorm-don-t-trigger-the-watcher huh... The more you know.... But it's weird I didn't have this problem before |
That's very good to hear! I know it sucks to have to disable safe write though, so I'm leaving this issue open to see if we can find a way that isn't necessary. I also added it to FAQs so other people can find it. Thanks to all that helped test this and came up with solutions, you guys rock! |
I had this issue on NVIM/VIM, not using Webstorm. |
i have exactly the same issue on Win 10, with IntelliJ IDEA and rc0-rc4. an "old" cli beta-version works perfectly. deactivating "safe write" fixed it for me. @instantepiphany |
I had the same problem until I stopped using --aot=true and now anytime I save a file the changes are picked up properly. What is aot doing that would cause the changes not to be picked up? |
Guys, I am using Visual Studio Code and getting same problem, I couldn't find 'safe write' thing in my IDE. |
Hi @jamilalisgandarov |
@instantepiphany, with VIM you can use the solution from here: |
@hpawe01 This seems to fix the issue for me, thanks so much for the link! |
Are there two different mechanisms being used to detect the changes? When I save in VIM (without the |
Consolidating this thread with #1610, it's roughly the same and better to keep discussion in a single place. |
@ovalol u are totally right |
The same behaviour here with |
@mejmo make Safe-write option in WebStorm disabled. |
It helped and solved the issue. Thank you. |
@filipesilva Instead of disabling safe-write is it possible to base watches off of actual file changes? Clearly the mtime of a file will change, but if the contents are exactly the same should it really fire off a recompile? If I have webstorm open, and I just click on the window, and then click on the browser window, it still recompiles, interrupting my workflow. Even if the file hasn't changed. |
What is the "safe-write" setting for SourceTree? For some reason whatever SourceTree does to refresh is causing a recompile. This seems kind of silly because some other alert could come along and force Windows to refresh it's GDM. It doesn't seem like "developing angular" should be interrupted by whichever OS you are using. |
Disabling safe-write didn't change anything for me. Still recompiles even though nothing has changed. |
I have the opposite of this problem, it reloads too often because webstorm changes file times behind my back and their is no way to ignore it with the cli #8033 (comment) |
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
OS?
Windows 10
Versions.
@angular/cli: 1.0.0-rc.0
node: 7.5.0
os: win32 x64
@angular/common: 2.4.8
@angular/compiler: 2.4.8
@angular/core: 2.4.8
@angular/forms: 2.4.8
@angular/http: 2.4.8
@angular/platform-browser: 2.4.8
@angular/platform-browser-dynamic: 2.4.8
@angular/router: 3.4.8
@angular/cli: 1.0.0-rc.0
@angular/compiler-cli: 2.4.8
Repro steps.
Happens all the time since update from beta version
Since I updated, ng serve doesn't rerender the file.
It sees the files that have changed and launches a recompilation but the changes don't get included.
It doesn't do this for a couple of recompilations then it refuses to update the files.
What kind of details can I give you?
Thanks
The text was updated successfully, but these errors were encountered: