Closed tatsujb closed 5 years ago
Can you share your angular.json please?
of course !
{
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
"version": 1,
"newProjectRoot": "projects",
"projects": {
"web.ui": {
"root": "",
"sourceRoot": "src",
"projectType": "application",
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:browser",
"options": {
"outputPath": "dist",
"index": "src/index.html",
"main": "src/main.ts",
"tsConfig": "src/tsconfig.app.json",
"polyfills": "src/polyfills.ts",
"assets": [
"src/assets",
"src/favicon.ico",
"src/assets/images"
],
"styles": [
"node_modules/ion-rangeslider/css/ion.rangeSlider.css",
"node_modules/font-awesome/css/font-awesome.css",
"node_modules/bootstrap/dist/css/bootstrap.min.css"
],
"scripts": [
"node_modules/jquery/dist/jquery.min.js",
"node_modules/ion-rangeslider/js/ion.rangeSlider.min.js"
]
},
"configurations": {
"en": {
"aot": true,
"outputPath": "dist/en/",
"i18nFile": "src/locale/english.xlf",
"i18nFormat": "xlf",
"i18nLocale": "en",
"i18nMissingTranslation": "error"
},
"production": {
"fileReplacements": [
{
"replace": "src/environments/environment.ts",
"with": "src/environments/environment.prod.ts"
}
],
"optimization": true,
"outputHashing": "all",
"sourceMap": false,
"extractCss": true,
"namedChunks": false,
"aot": true,
"extractLicenses": true,
"vendorChunk": false,
"buildOptimizer": true
},
"production-en": {
"fileReplacements": [
{
"replace": "src/environments/environment.ts",
"with": "src/environments/environment.prod.ts"
}
],
"optimization": true,
"outputHashing": "all",
"sourceMap": false,
"extractCss": true,
"namedChunks": false,
"aot": true,
"extractLicenses": true,
"vendorChunk": false,
"buildOptimizer": true,
"outputPath": "dist/my-project-en/",
"i18nFile": "src/locale/english.xlf",
"i18nFormat": "xlf",
"i18nLocale": "en",
"i18nMissingTranslation": "error"
}
}
},
"serve": {
"builder": "@angular-devkit/build-angular:dev-server",
"options": {
"browserTarget": "web.ui:build"
},
"configurations": {
"production": {
"browserTarget": "web.ui:build:production"
},
"en": {
"browserTarget": "web.ui:build:en"
},
"production-en": {
"browserTarget": "web.ui:build:production-en"
}
}
},
"extract-i18n": {
"builder": "@angular-devkit/build-angular:extract-i18n",
"options": {
"browserTarget": "web.ui:build"
}
},
"lint": {
"builder": "@angular-devkit/build-angular:tslint",
"options": {
"tsConfig": [
"src/tsconfig.app.json"
],
"exclude": [
"**/node_modules/**"
]
}
}
}
},
"web.ui-e2e": {
"root": "",
"sourceRoot": "",
"projectType": "application"
}
},
"defaultProject": "web.ui",
"cli": {
"warnings": {
"typescriptMismatch": false
}
},
"schematics": {
"@schematics/angular:component": {
"prefix": "app",
"styleext": "scss"
},
"@schematics/angular:directive": {
"prefix": "app"
}
}
}
Thanks but I asked for your angular.json
.
it's updated, my bad.
The Found a modern configuration file. Nothing to be done.
message is just an info message.
I have tried using both your angular.json
and package.json
and I am unable to replicate the same issue.
λ ng update @angular/cli @angular/core
Updating package.json with dependency @angular/language-service @ "7.0.1" (was "6.1.10")...
Updating package.json with dependency @angular/animations @ "7.0.1" (was "6.1.10")...
Updating package.json with dependency @angular/core @ "7.0.1" (was "6.1.10")...
Updating package.json with dependency @angular/compiler @ "7.0.1" (was "6.1.10")...
Updating package.json with dependency @angular/common @ "7.0.1" (was "6.1.10")...
Updating package.json with dependency @angular/http @ "7.0.1" (was "6.1.10")...
Updating package.json with dependency @angular/forms @ "7.0.1" (was "6.1.10")...
Updating package.json with dependency @angular/platform-browser @ "7.0.1" (was "6.1.10")...
Updating package.json with dependency @angular/compiler-cli @ "7.0.1" (was "6.1.10")...
Updating package.json with dependency @angular/platform-browser-dynamic @ "7.0.1" (was "6.1.10")...
Updating package.json with dependency @angular/router @ "7.0.1" (was "6.1.10")...
Updating package.json with dependency @angular/cli @ "7.0.3" (was "6.2.3")...
Updating package.json with dependency typescript @ "3.1.4" (was "2.7.2")...
UPDATE package.json (1861 bytes)
npm WARN @angular/cdk@6.4.7 requires a peer of @angular/core@>=6.0.0-beta.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/cdk@6.4.7 requires a peer of @angular/common@>=6.0.0-beta.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/material@6.4.7 requires a peer of @angular/core@>=6.0.0-beta.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/material@6.4.7 requires a peer of @angular/common@>=6.0.0-beta.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/material-moment-adapter@6.4.7 requires a peer of @angular/core@>=6.0.0-beta.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @ncstate/sat-popover@2.1.1 requires a peer of @angular/common@^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @ncstate/sat-popover@2.1.1 requires a peer of @angular/core@^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @ngtools/webpack@6.1.5 requires a peer of typescript@~2.4.0 || ~2.5.0 || ~2.6.0 || ~2.7.0 || ~2.8.0 || ~2.9.0 but none is installed. You must install peer dependencies yourself.
npm WARN ng-snotify@4.3.1 requires a peer of @angular/core@^4.0.0 || ^5.0.0 || ^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
added 64 packages from 62 contributors, removed 8 packages, updated 21 packages, moved 2 packages and audited 37185 packages in 23.267s
found 0 vulnerabilities
UPDATE package.json (1863 bytes)
UPDATE src/polyfills.ts (3234 bytes)
> node-sass@4.9.3 install C:\git\cli-repos\test-up\node_modules\node-sass
> node scripts/install.js
Cached binary found at C:\Users\alag\AppData\Roaming\npm-cache\node-sass\4.9.3\win32-x64-64_binding.node
> node-sass@4.9.3 postinstall C:\git\cli-repos\test-up\node_modules\node-sass
> node scripts/build.js
Binary found at C:\git\cli-repos\test-up\node_modules\node-sass\vendor\win32-x64-64\binding.node
Testing binary
Binary is fine
npm WARN @angular/cdk@6.4.7 requires a peer of @angular/core@>=6.0.0-beta.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/cdk@6.4.7 requires a peer of @angular/common@>=6.0.0-beta.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/material@6.4.7 requires a peer of @angular/core@>=6.0.0-beta.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/material@6.4.7 requires a peer of @angular/common@>=6.0.0-beta.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/material-moment-adapter@6.4.7 requires a peer of @angular/core@>=6.0.0-beta.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @ncstate/sat-popover@2.1.1 requires a peer of @angular/common@^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @ncstate/sat-popover@2.1.1 requires a peer of @angular/core@^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN ng-snotify@4.3.1 requires a peer of @angular/core@^4.0.0 || ^5.0.0 || ^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
added 53 packages from 67 contributors, removed 67 packages, updated 48 packages, moved 1 package and audited 36824 packages in 30.125s
found 0 vulnerabilities
Can you share a reproduction, also if you run ng update
does it output the correct versions?
am I supposed to delete node_modules to have better success with ng update @angular/cli ?
I can't really share my whole project as it is corporate.
what could be causing the issue that isn't the package.json file or the angular.json file?
could it be missing packages? wrong imports? scss?
Not really, you should be needing to remove the node_modules
.
Can you post what does ng update
outputs in the console (note: no packages specified)?
shouldn't or should?
ng update is still running. just like ng update @angular/cli it takes about 10 mins, is this normal?
ng update
should output something like
We analyzed your package.json, there are some packages to update:
Name Version Command to update
--------------------------------------------------------------------------------
@angular/cdk 6.4.7 -> 7.0.2 ng update @angular/cdk
@angular/cli 6.0.0 -> 7.0.3 ng update @angular/cli
@angular/material 6.4.7 -> 7.0.2 ng update @angular/material
There might be additional packages that are outdated.
Or run ng update --all to try to update all at the same time.
ng update
We analyzed your package.json, there are some packages to update:
Name Version Command to update
--------------------------------------------------------------------------------
@angular/cdk 6.4.7 -> 7.0.2 ng update @angular/cdk
@angular/cli 6.2.3 -> 7.0.3 ng update @angular/cli
@angular/core 6.1.9 -> 7.0.1 ng update @angular/core
@angular/material 6.4.7 -> 7.0.2 ng update @angular/material
There might be additional packages that are outdated.
Or run ng update --all to try to update all at the same time.
maybe update --all will work?
>ng update --all
Package "@ncstate/sat-popover" has an incompatible peer dependency to "@angular/cdk" (requires "^6.0.0", would install "7.0.2").
Incompatible peer dependencies found. See above.
i removed that package, trying without....
ok that worked, thanks for the help! sat-popover
was the culprit : https://www.npmjs.com/package/@ncstate/sat-popover
>ng update --all
Updating package.json with dependency file-saver @ "2.0.0-rc.4" (was "1.3.8")...
Updating package.json with dependency ngx-bootstrap @ "3.1.1" (was "3.0.1")...
Updating package.json with dependency @angular-devkit/build-angular @ "0.10.3" (was "0.7.5")...
Updating package.json with dependency @types/jasmine @ "2.8.9" (was "2.8.8")...
Updating package.json with dependency @angular/cdk @ "7.0.2" (was "6.4.7")...
Updating package.json with dependency @types/jasminewd2 @ "2.0.5" (was "2.0.4")...
Updating package.json with dependency @angular/http @ "7.0.1" (was "6.1.9")...
Updating package.json with dependency @angular/material-moment-adapter @ "7.0.2" (was "6.4.7")...
Updating package.json with dependency postcss-modules @ "1.4.1" (was "1.3.2")...
Updating package.json with dependency @angular/compiler @ "7.0.1" (was "6.1.9")...
Updating package.json with dependency @angular/platform-browser-dynamic @ "7.0.1" (was "6.1.9")...
Updating package.json with dependency codelyzer @ "4.5.0" (was "4.4.4")...
Updating package.json with dependency @angular/router @ "7.0.1" (was "6.1.9")...
Updating package.json with dependency @angular/animations @ "7.0.1" (was "6.1.9")...
Updating package.json with dependency @angular/platform-browser @ "7.0.1" (was "6.1.9")...
Updating package.json with dependency @angular/common @ "7.0.1" (was "6.1.9")...
Updating package.json with dependency @angular/compiler-cli @ "7.0.1" (was "6.1.9")...
Updating package.json with dependency @angular/forms @ "7.0.1" (was "6.1.9")...
Updating package.json with dependency @angular/material @ "7.0.2" (was "6.4.7")...
Updating package.json with dependency @angular/language-service @ "7.0.1" (was "6.1.9")...
Updating package.json with dependency @angular/core @ "7.0.1" (was "6.1.9")...
Updating package.json with dependency @types/node @ "10.12.1" (was "10.7.2")...
Updating package.json with dependency @angular/cli @ "7.0.3" (was "6.2.3")...
Updating package.json with dependency typescript @ "3.1.4" (was "2.7.2")...
UPDATE package.json (1831 bytes)
npm WARN ng-snotify@4.3.1 requires a peer of @angular/core@^4.0.0 || ^5.0.0 || ^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN ajv-keywords@3.2.0 requires a peer of ajv@^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
added 88 packages, removed 109 packages, updated 97 packages and moved 16 packages in 213.19s
UPDATE package.json (1832 bytes)
UPDATE src/polyfills.ts (2325 bytes)
npm WARN rollback Rolling back wrappy@1.0.2 failed (this is probably harmless): EPERM: operation not permitted, lstat 'C:\Users\j_bard\WebstormProjects\AirConnect\web\web.ui\node_modules\fsevents\node_modules'
npm WARN ajv-keywords@3.2.0 requires a peer of ajv@^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN ng-snotify@4.3.1 requires a peer of @angular/core@^4.0.0 || ^5.0.0 || ^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
up to date in 30.812s
✓ Angular Material update complete
⚠ Please check the output above for any issues that were detected but could not be automatically fixed.
ng update --all worked for me as well.. but I was not expecting that this would also update things like moment-timezone, intersection-observer, localforage etc...
Is this really the correct behavior?
yes I believe so. it reads "update all"
@tatsujb but should it not be specific to angular and related packages only? What's the difference from running npm/yarn upgrade?
none I guess.
It runs migrations for packages containing them.
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.
Bug Report or Feature Request (mark with an
x
)Command (mark with an
x
)Versions
v8.9.4
5.6.0
ng --version
Angular CLI: 6.2.3 Node: 8.9.4 OS: win32 x64 Angular: 6.1.9 ... animations, common, compiler, compiler-cli, core, forms ... http, language-service, platform-browser ... platform-browser-dynamic, router
Package Version
@angular-devkit/architect 0.7.5 @angular-devkit/build-angular 0.7.5 @angular-devkit/build-optimizer 0.7.5 @angular-devkit/build-webpack 0.7.5 @angular-devkit/core 0.7.5 @angular-devkit/schematics 0.8.3 @angular/cdk 6.4.7 @angular/cli 6.2.3 @angular/material 6.4.7 @angular/material-moment-adapter 6.4.7 @ngtools/webpack 6.1.5 @schematics/angular 0.8.3 @schematics/update 0.8.3 rxjs 6.3.3 typescript 2.7.2 webpack 4.9.2
ng update @angular/cli
Found a modern configuration file. Nothing to be done.
ng update @angular/cli @angular/core
--from requires that only a single package be passed.
ng update @angular/cli
Found a modern configuration file. Nothing to be done.