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

TypeError: Cannot read property 'apply' of undefined in CachedInputFileSystem.js #9561

Closed
torsten-simon opened this issue Feb 8, 2018 · 10 comments

Comments

@torsten-simon
Copy link

torsten-simon commented Feb 8, 2018

Versions

Angular CLI: 1.6.8
Node: 8.9.4
OS: win32 x64
Angular: 5.2.4
... animations, common, compiler, compiler-cli, core, forms
... http, platform-browser, platform-browser-dynamic, router

@angular/cli: 1.6.8
@angular-devkit/build-optimizer: 0.0.42
@angular-devkit/core: 0.0.29
@angular-devkit/schematics: 0.0.52
@ngtools/json-schema: 1.1.0
@ngtools/webpack: 1.9.8
@schematics/angular: 0.1.17
typescript: 2.4.2
webpack: 3.10.0

Repro steps

Running ng server or ng build on the project
Use the repository from here:
https://github.com/tsimon-edu-sharing/cli-sample

Observed behavior

** NG Live Development Server is listening on localhost:4200, open your browser on http://localhost:4200/ **
 95% emittingC:\Users\project\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:70
                                callback.apply(null, data);
                                         ^

TypeError: Cannot read property 'apply' of undefined
    at C:\Users\project\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:70:14
    at _combinedTickCallback (internal/process/next_tick.js:131:7)
    at process._tickCallback (internal/process/next_tick.js:180:9)

Desired behavior

Should run / build, or give a more useful error

Mention any other details that might be useful (optional)

Reason seems to have something to do with including the font stylesheet via the angular-cli.json

@JoshDSommer
Copy link

JoshDSommer commented Feb 8, 2018

I'm having the same problem with the latest version of the Angular CLI (1.6.8). I've resolved this by temporarily setting the Angular CLI version in my package.json to 1.6.7

@d2kx
Copy link

d2kx commented Feb 8, 2018

Yep. Same.

@torsten-simon
Copy link
Author

Thanks @TheOriginalJosh , that helped for now!

@ukon1990
Copy link

ukon1990 commented Feb 8, 2018

Hmm odd.. I seemed to have the same issue. but then it was suddenly gone... Can't say that I did any changes other than trying to revert stuff to older versions and then resat it back to where it all started.

@n1ebrown
Copy link

n1ebrown commented Feb 8, 2018

Pinning to 1.6.7 addressed the issue for now.

@micahwood
Copy link

I experienced this issue briefly while still on 1.6.6, and like everyone else it went away on it's own.

@micahwood
Copy link

Looks like it was an issue with copy-webpack-plugin@4.4.0. Once it started working again it installed 4.4.1 which fixed this issue.

webpack-contrib/copy-webpack-plugin#221

@hansl
Copy link
Contributor

hansl commented Feb 8, 2018

Closing this as fixed in copy-webpack-plugin. Please update your node_modules folder and you should be good to go.

@hansl hansl closed this as completed Feb 8, 2018
@leenMalka
Copy link

leenMalka commented May 1, 2018

@TheOriginalJosh
Hey I tried your answer to change version of angular/cli
but the still throw this error

95% emittingX:\NewClalWeb\base-project\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:70
callback.apply(null, data);
^
TypeError: Cannot read property 'apply' of undefined

at X:\NewClalWeb\base-project\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:70:14

at _combinedTickCallback (internal/process/next_tick.js:131:7)

at process._tickCallback (internal/process/next_tick.js:180:9)

@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 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants