You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
First build ran successfully. I can see the cache folders for angular-webpack and babel-webpack and cache files created.
Second build, there are lot of warning (from pack: TypeError: Cannot read property of 'map' of undefined). If I replace the custom-webpack with @angular-devkit/build-angular, persistent cache works. I also noted the first build take much longer (22minutes) when using @angular-builders/custom-webpack compare to @angular-devkit/build-angular (10mins)
The error come from here :
The same issue also happens when I use @Angular-builder/custom-webpack 12.1.0
Eventually, the build completed but it doesnt look like there is any cache restore happens as seen from the capture above
angular.json
"architect": {
"build": {
"builder": "@angular-builders/custom-webpack:browser",
//"builder": "@angular-devkit/build-angular:browser",
"options": {
"customWebpackConfig": {
"path": "./webpack.config.js",
"mergeRules": {
"output": "replace",
"entry": "replace"
},
"replaceDuplicatePlugins": true
},
"outputPath": "./dev-build",
"index": "",
"main": "app/silverlight/silverlight.bootstrap.ts",
"polyfills": "app/polyfills.ts",
"tsConfig": "./tsconfig.json",
"inlineStyleLanguage": "scss"
@just-jeb I commented out my custom webpack config module.exports = {} and it still doesnt work (take a long time with persistent cache turn on). I think this must be related to custom webpack. I also came across a comment here where the user said the custom webpack causes performance issue angular/angular-cli#20792 (comment)
Hey, thanks for checking it out for me. I can't think of anything that would cause the custom-webpack multiply the build time.
Any chance you can try clean install (with removing the package-lock.json) like they did here?
If it still doesn't help I'm gonna need a reproduction.
Thank you.
Describe the Bug
Restoring failed for persistent caching
Minimal Reproduction
Angular CLI 12.1.1,
Angular-Builders/Custom-Webpack 12.1.1.beta
First build ran successfully. I can see the cache folders for angular-webpack and babel-webpack and cache files created.
Second build, there are lot of warning (from pack: TypeError: Cannot read property of 'map' of undefined). If I replace the custom-webpack with @angular-devkit/build-angular, persistent cache works. I also noted the first build take much longer (22minutes) when using @angular-builders/custom-webpack compare to @angular-devkit/build-angular (10mins)
The error come from here :
The same issue also happens when I use @Angular-builder/custom-webpack 12.1.0
Eventually, the build completed but it doesnt look like there is any cache restore happens as seen from the capture above
angular.json
"architect": {
"build": {
"builder": "@angular-builders/custom-webpack:browser",
//"builder": "@angular-devkit/build-angular:browser",
"options": {
"customWebpackConfig": {
"path": "./webpack.config.js",
"mergeRules": {
"output": "replace",
"entry": "replace"
},
"replaceDuplicatePlugins": true
},
"outputPath": "./dev-build",
"index": "",
"main": "app/silverlight/silverlight.bootstrap.ts",
"polyfills": "app/polyfills.ts",
"tsConfig": "./tsconfig.json",
"inlineStyleLanguage": "scss"
Expected Behavior
Persistent cache restore cache item successfully. The build time should reduce as the result of Persistent caching working
The text was updated successfully, but these errors were encountered: