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

Missing vendor bundle when using a common node_modules directory #6499

Closed
toff opened this issue May 29, 2017 · 1 comment · Fixed by #6514
Closed

Missing vendor bundle when using a common node_modules directory #6499

toff opened this issue May 29, 2017 · 1 comment · Fixed by #6514
Labels
effort1: easy (hours) freq1: low Only reported by a handful of users who observe it rarely P5 The team acknowledges the request but does not plan to address it, it remains open for discussion severity2: inconvenient type: bug/fix workaround2: non-obvious

Comments

@toff
Copy link

toff commented May 29, 2017

Bug Report or Feature Request (mark with an x)

- [x] bug report -> please search issues before submitting
- [ ] feature request

Versions.

@angular/cli: 1.0.6
node: 7.8.0
os: linux ia32 (Centos 6)

Repro steps.

  1. Create and compile a new project :
$ ng new ngcli

$ cd ngcli

$ npm start
> ngcli@0.0.0 start /tmp/ngcli
> ng serve
** NG Live Development Server is listening on localhost:4200, open your browser on http://localhost:4200 **
Hash: 05d9399d72c600d01b08
Time: 7157ms
chunk    {0} polyfills.bundle.js, polyfills.bundle.js.map (polyfills) 158 kB {4} [initial] [rendered]
chunk    {1} main.bundle.js, main.bundle.js.map (main) 3.63 kB {3} [initial] [rendered]
chunk    {2} styles.bundle.js, styles.bundle.js.map (styles) 10.5 kB {4} [initial] [rendered]
chunk    {3} vendor.bundle.js, vendor.bundle.js.map (vendor) 2.4 MB [initial] [rendered]
chunk    {4} inline.bundle.js, inline.bundle.js.map (inline) 0 bytes [entry] [rendered]
webpack: Compiled successfully.

Notice the existence of chunk {3} vendor.bundle.js

  1. Instead of using current project node_modules folder use a common parent folder :
$ mv node_modules ..

$ ln -s ../node_modules

$ npm start
> ngcli@0.0.0 start /tmp/ngcli
> ng serve
** NG Live Development Server is listening on localhost:4200, open your browser on http://localhost:4200 **
Hash: f9ab2a4dda50da8c05cc
Time: 12165ms
chunk    {0} polyfills.bundle.js, polyfills.bundle.js.map (polyfills) 158 kB {3} [initial] [rendered]
chunk    {1} styles.bundle.js, styles.bundle.js.map (styles) 10.5 kB {3} [initial] [rendered]
chunk    {2} main.bundle.js, main.bundle.js.map (main) 2.41 MB [initial] [rendered]
chunk    {3} inline.bundle.js, inline.bundle.js.map (inline) 0 bytes [entry] [rendered]
webpack: Compiled successfully.

As you can see the vendor bundle is now missing.

The log given by the failure.

No failure

Desired functionality.

Generate the vendor bundle.

Mention any other details that might be useful.

Modifying node_modules/@angular/cli/models/webpack-configs/common.js with resolve: { symlinks: false, ... seems to fix the problem.
But I don't know if there is any drawback.

@hansl hansl added type: bug/fix effort1: easy (hours) freq1: low Only reported by a handful of users who observe it rarely package1: @angular/cli P5 The team acknowledges the request but does not plan to address it, it remains open for discussion severity2: inconvenient workaround2: non-obvious and removed type: RFC / discussion / question labels May 30, 2017
@hansl hansl assigned hansl and unassigned filipesilva May 30, 2017
hansl added a commit to hansl/angular-cli that referenced this issue May 30, 2017
hansl added a commit to hansl/angular-cli that referenced this issue May 31, 2017
hansl added a commit to hansl/angular-cli that referenced this issue May 31, 2017
hansl added a commit to hansl/angular-cli that referenced this issue May 31, 2017
dond2clouds pushed a commit to d2clouds/speedray-cli that referenced this issue Apr 23, 2018
@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
effort1: easy (hours) freq1: low Only reported by a handful of users who observe it rarely P5 The team acknowledges the request but does not plan to address it, it remains open for discussion severity2: inconvenient type: bug/fix workaround2: non-obvious
Projects
None yet
4 participants