Skip to content

this._compilerHost.resolve is not a function #11909

@echo-sean

Description

@echo-sean

Bug Report or Feature Request (mark with an x)

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

Command (mark with an x)

- [ ] new
- [x] build
- [x] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [ ] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc

Versions

Node v8.11.1
NPM 6.1.0

Package Version before Version after
@angular-devkit/build-angular 0.6.8 0.7.3
@angular/animations 6.0.9 6.1.2
@angular/cli 6.0.8 6.1.3
@angular/common 6.0.9 6.1.2
@angular/compiler 6.0.9 6.1.2
@angular/compiler-cli 6.0.9 6.1.2
@angular/core 6.0.9 6.1.2
@angular/forms 6.0.9 6.1.2
@angular/language-service 6.0.9 6.1.2
@angular/platform-browser 6.0.9 6.1.2
@angular/platform-browser-dynamic 6.0.9 6.1.2
@angular/router 6.0.9 6.1.2
typescript 2.7.2 2.9.2

Repro steps

  • update Angular dependencies (as above)
  • run ng build --prod --configuration=production

The log given by the failure

this._compilerHost.resolve is not a function
TypeError: this._compilerHost.resolve is not a function
    at compiler.hooks.environment.tap (/PATH_TO_PROJECT/node_modules/@ngtools/webpack/src/angular_compiler_plugin.js:455:53)
    at SyncHook.eval [as call] (eval at create (/PATH_TO_PROJECT/node_modules/tapable/lib/HookCodeFactory.js:17:12), <anonymous>:7:1)
    at SyncHook.lazyCompileHook [as _call] (/PATH_TO_PROJECT/node_modules/tapable/lib/Hook.js:35:21)
    at webpack (/PATH_TO_PROJECT/node_modules/webpack/lib/webpack.js:40:30)
    at Observable.rxjs_1.Observable.obs [as _subscribe] (/PATH_TO_PROJECT/node_modules/@angular-devkit/build-webpack/src/webpack/index.js:21:37)
    at Observable._trySubscribe (/PATH_TO_PROJECT/node_modules/rxjs/internal/Observable.js:43:25)
    at Observable.subscribe (/PATH_TO_PROJECT/node_modules/rxjs/internal/Observable.js:29:22)
    at /PATH_TO_PROJECT/node_modules/rxjs/internal/util/subscribeTo.js:22:31
    at Object.subscribeToResult (/PATH_TO_PROJECT/node_modules/rxjs/internal/util/subscribeToResult.js:7:45)
    at MergeMapSubscriber._innerSub (/PATH_TO_PROJECT/node_modules/rxjs/internal/operators/mergeMap.js:75:38)
    at MergeMapSubscriber._tryNext (/PATH_TO_PROJECT/node_modules/rxjs/internal/operators/mergeMap.js:72:14)
    at MergeMapSubscriber._next (/PATH_TO_PROJECT/node_modules/rxjs/internal/operators/mergeMap.js:55:18)
    at MergeMapSubscriber.Subscriber.next (/PATH_TO_PROJECT/node_modules/rxjs/internal/Subscriber.js:64:18)
    at TapSubscriber._next (/PATH_TO_PROJECT/node_modules/rxjs/internal/operators/tap.js:62:26)
    at TapSubscriber.Subscriber.next (/PATH_TO_PROJECT/node_modules/rxjs/internal/Subscriber.js:64:18)
    at MergeMapSubscriber.notifyNext (/PATH_TO_PROJECT/node_modules/rxjs/internal/operators/mergeMap.js:84:26)

Desired functionality

Build should not fail

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions