Skip to content

ng serve --aot serves stale app #2576

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

Closed
jeffbcross opened this issue Oct 7, 2016 · 5 comments
Closed

ng serve --aot serves stale app #2576

jeffbcross opened this issue Oct 7, 2016 · 5 comments
Assignees
Labels
P1 Impacts a large percentage of users; if a workaround exists it is partial or overly painful

Comments

@jeffbcross
Copy link
Contributor

OS?

Windows 7, 8 or 10. Linux (which distribution). Mac OSX (Yosemite? El Capitan?)

El Capitan

Versions.

Please run ng --version. If there's nothing outputted, please run in a Terminal: node --version and paste the result here:

beta.17 (experimental)

Repro steps.

Was this an app that wasn't created using the CLI? What change did you do on your code? etc.

See this commit: jeffbcross/cli-aot-route-bug@85bd5c6

I just added a route config and a couple of components (though I don't think this is a router-specific issue).

  1. Serve the app using ng serve --aot
  2. App should work as expected
  3. Change a route config in src/app/app.module.ts (i.e. set homeRoute.component to ItemsComponent
  4. When page refreshes automatically, the old config will still be present (also happens after manually refreshing)
  5. Make any change to app.module.ts and save (like add a newline at the end of file)
  6. Page refreshes with configuration changes made in step 3.
@filipesilva filipesilva added the P1 Impacts a large percentage of users; if a workaround exists it is partial or overly painful label Oct 7, 2016
@jeffbcross
Copy link
Contributor Author

Note: I added a commit after the repro commit that would cause AoT to break because I added a then() to console log after bootstrapModule. Just remove that callback to get rid of Tried to find bootstrap code, but could not. message.

@hansl
Copy link
Contributor

hansl commented Feb 10, 2017

Closing this as deprecated. We cannot reproduce this and the webpack plugin has improved a lot in the last 3 months.

@hansl hansl closed this as completed Feb 10, 2017
@konrad-garus
Copy link

I'm still suffering this on beta.30.

@KrystianRos
Copy link

Still the same problem:

@angular/cli: 1.1.0
node: 6.11.0
os: win32 x64
@angular/animations: 4.2.5
@angular/common: 4.2.5
@angular/compiler: 4.2.5
@angular/core: 4.2.5
@angular/forms: 4.2.5
@angular/http: 4.2.5
@angular/platform-browser: 4.2.5
@angular/platform-browser-dynamic: 4.2.5
@angular/router: 4.2.5
@angular/cli: 1.1.0
@angular/compiler-cli: 4.2.5
@angular/language-service: 4.2.5

@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 7, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
P1 Impacts a large percentage of users; if a workaround exists it is partial or overly painful
Projects
None yet
Development

No branches or pull requests

5 participants