From 45e97d64aae26468cf45738400cdf64b7a48e41c Mon Sep 17 00:00:00 2001 From: "Kristian D. Dimitrov" Date: Fri, 18 Oct 2019 13:23:03 +0300 Subject: [PATCH 1/3] chore:bump version to 6.2.1 --- npm-shrinkwrap.json | 2 +- package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/npm-shrinkwrap.json b/npm-shrinkwrap.json index 8eddd47080..f51552202e 100644 --- a/npm-shrinkwrap.json +++ b/npm-shrinkwrap.json @@ -1,6 +1,6 @@ { "name": "nativescript", - "version": "6.2.0", + "version": "6.2.1", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 9eb590f2e0..06cd007e91 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "nativescript", "preferGlobal": true, - "version": "6.2.0", + "version": "6.2.1", "author": "Telerik ", "description": "Command-line interface for building NativeScript projects", "bin": { From 1e9a55e2259a7fcdae679bd44d9073b4e33bd863 Mon Sep 17 00:00:00 2001 From: Kristian Dimitrov Date: Wed, 23 Oct 2019 13:39:38 +0300 Subject: [PATCH 2/3] chore: add trace for shouldMigrate caching --- lib/controllers/migrate-controller.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/controllers/migrate-controller.ts b/lib/controllers/migrate-controller.ts index 0b7d041408..ec49989a85 100644 --- a/lib/controllers/migrate-controller.ts +++ b/lib/controllers/migrate-controller.ts @@ -163,11 +163,14 @@ Running this command will ${MigrateController.COMMON_MIGRATE_MESSAGE}`; const cachedResult = await this.getCachedShouldMigrate(projectDir, platform); if (cachedResult !== false) { remainingPlatforms.push(platform); + } else { + this.$logger.trace(`Got cached result for shouldMigrate for platform: ${platform}`); } } if (remainingPlatforms.length > 0) { shouldMigrate = await this._shouldMigrate({ projectDir, platforms: remainingPlatforms, allowInvalidVersions }); + this.$logger.trace(`Executed shouldMigrate for platforms: ${remainingPlatforms}. Result is: ${shouldMigrate}`); if (!shouldMigrate) { for (const remainingPlatform of remainingPlatforms) { From 516fd310d4b7953c9448ca34bfb429a55b99c50d Mon Sep 17 00:00:00 2001 From: fatme Date: Tue, 29 Oct 2019 09:40:36 +0200 Subject: [PATCH 3/3] fix: handle correctly the situation when the compilation hash is the same as the previous one MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Currently CLI considers the hash that is the same as the previous as invalid and this way the application is restarted on device. As that hash is already handled, we should consider it as a valid hash. Steps to reproduce : ``` `tns create ts_proj` - choose ts tabs project npm i tns-core-modules@rc --save --save-exact npm i nativescript-dev-webpack@rc --save-dev --save-exact node_modules/.bin/update-ns-webpack --deps –configs tns run android Change something in app.android.scss - the change is applied, no restart Change something in app.ios.scss - application restarts ``` --- lib/services/webpack/webpack-compiler-service.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/services/webpack/webpack-compiler-service.ts b/lib/services/webpack/webpack-compiler-service.ts index 4f0dd015da..297e306bef 100644 --- a/lib/services/webpack/webpack-compiler-service.ts +++ b/lib/services/webpack/webpack-compiler-service.ts @@ -46,6 +46,11 @@ export class WebpackCompilerService extends EventEmitter implements IWebpackComp return; } + // the hash of the compilation is the same as the previous one + if (this.expectedHashes[platformData.platformNameLowerCase] === message.hash) { + return; + } + let result; if (prepareData.hmr) {