Closed krishnagopinath closed 5 years ago
Hi @krishnagopinath , Thanks for reporting!
Yeah, It is strange issue. Could you please clarify do you have this behavior for all releases in Production
deployment or only for this one?
Thanks, Alexander
Hey @alexandergoncharov :wave:
Thank you for the response!
Could you please clarify do you have this behavior for all releases in Production deployment or only for this one
I'd say that this issue has been slowly building up :disappointed:
Here are the logs for all the releases we did, targeting 3.11.x
. The first one (v21
) is the app store deployment and everything else has been codepush releases. We use code-push
CLI's release-cordova
command to release updates. We don't use appcenter (yet).
Also, another question: Is there any way we could look at these rollback logs? We're using Sentry at the moment and the logs are barely sufficient :(
@krishnagopinath oh, I see. Unfortunately, there isn't any approach for checking reason of rollbacks. It should be in logs like some Error or something like that.
We're using Sentry at the moment and the logs are barely sufficient
Anyway, could you please provide this logs?
Here's how a typical log would look like:
In the past two weeks, this error has happened 5.4k times on users' devices.
21:02:29 [CodePush] Checking for update.
21:02:29 [CodePush] An update is available. {"appVersion":"3.11.0","deploymentKey":"******","description":"","downloadUrl":"*****,"isMandatory":false,"label":"v23","packageHash":"c823d4d9095025f661e16c775ad51f4a52148046bda0260031624871830e42f6","packageSize":964590,"failedInstall":false}
21:02:29 [CodePush] Downloading update
21:02:32 [CodePush] Package download success: {"deploymentKey":"****","description":"","label":"v23","appVersion":"3.11.0","isMandatory":false,"packageHash":"c823d4d9095025f661e16c775ad51f4a52148046bda0260031624871830e42f6","isFirstRun":false,"failedInstall":false,"localPath":"cdvfile://localhost/library-nosync/codepush/download/update.zip"}
21:02:32 [CodePush] Installing update
21:02:33 [CodePush] Cannot perform diff-update.. StackTrace: file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-code-push/bin/www/localPackage.js:360:46
onloadend@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-code-push/bin/www/fileUtil.js:232:25
readSuccessCallback@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-file/www/FileReader.js:164:27
readSuccessCallback@[native code]
callbackFromNative@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/cordova.js:291:63
nc2@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/cordova.js:1042:39
d@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/resources/raven.min.js:2:4572
21:02:33 [CodePush] An error occurred during sync. Cannot perform diff-update.. StackTrace: file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-code-push/bin/www/localPackage.js:360:46
onloadend@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-code-push/bin/www/fileUtil.js:232:25
readSuccessCallback@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-file/www/FileReader.js:164:27
readSuccessCallback@[native code]
callbackFromNative@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/cordova.js:291:63
nc2@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/cordova.js:1042:39
d@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/resources/raven.min.js:2:4572
21:10:23 [CodePush] Checking for update.
21:10:24 [CodePush] An update is available. {"appVersion":"3.11.0","deploymentKey":"****","description":"","downloadUrl":"****","isMandatory":false,"label":"v23","packageHash":"c823d4d9095025f661e16c775ad51f4a52148046bda0260031624871830e42f6","packageSize":964590,"failedInstall":false}
21:10:24 [CodePush] Downloading update
21:10:24 [CodePush] Package download success: {"deploymentKey":"****","description":"","label":"v23","appVersion":"3.11.0","isMandatory":false,"packageHash":"c823d4d9095025f661e16c775ad51f4a52148046bda0260031624871830e42f6","isFirstRun":false,"failedInstall":false,"localPath":"cdvfile://localhost/library-nosync/codepush/download/update.zip"}
21:10:24 [CodePush] Installing update
21:10:24 [CodePush] Cannot perform diff-update.. StackTrace: file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-code-push/bin/www/localPackage.js:360:46
onloadend@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-code-push/bin/www/fileUtil.js:232:25
readSuccessCallback@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-file/www/FileReader.js:164:27
readSuccessCallback@[native code]
callbackFromNative@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/cordova.js:291:63
nc2@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/cordova.js:1042:39
d@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/resources/raven.min.js:2:4572
21:10:24 [CodePush] An error occurred during sync. Cannot perform diff-update.. StackTrace: file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-code-push/bin/www/localPackage.js:360:46
onloadend@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-code-push/bin/www/fileUtil.js:232:25
readSuccessCallback@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-file/www/FileReader.js:164:27
readSuccessCallback@[native code]
callbackFromNative@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/cordova.js:291:63
nc2@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/cordova.js:1042:39
d@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/resources/raven.min.js:2:4572
21:15:42 [CodePush] Checking for update.
21:15:42 [CodePush] An update is available. {"appVersion":"3.11.0","deploymentKey":"****","description":"","downloadUrl":"****","isMandatory":false,"label":"v23","packageHash":"c823d4d9095025f661e16c775ad51f4a52148046bda0260031624871830e42f6","packageSize":964590,"failedInstall":false}
21:15:42 [CodePush] Downloading update
21:15:42 [CodePush] Package download success: {"deploymentKey":"****","description":"","label":"v23","appVersion":"3.11.0","isMandatory":false,"packageHash":"*****","isFirstRun":false,"failedInstall":false,"localPath":"cdvfile://localhost/library-nosync/codepush/download/update.zip"}
21:15:42 [CodePush] Installing update
21:15:43 [CodePush] Cannot perform diff-update.. StackTrace: file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-code-push/bin/www/localPackage.js:360:46
onloadend@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-code-push/bin/www/fileUtil.js:232:25
readSuccessCallback@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-file/www/FileReader.js:164:27
readSuccessCallback@[native code]
callbackFromNative@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/cordova.js:291:63
nc2@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/cordova.js:1042:39
d@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/resources/raven.min.js:2:4572
21:15:43 [CodePush] An error occurred during sync. Cannot perform diff-update.. StackTrace: file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-code-push/bin/www/localPackage.js:360:46
onloadend@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-code-push/bin/www/fileUtil.js:232:25
readSuccessCallback@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/plugins/cordova-plugin-file/www/FileReader.js:164:27
readSuccessCallback@[native code]
callbackFromNative@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/cordova.js:291:63
nc2@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/cordova.js:1042:39
d@file:///var/containers/Bundle/Application/6555910E-305D-4A1D-9B62-AD931844EED6/SWRemote.app/www/resources/raven.min.js:2:4572
Hi @krishnagopinath , Sorry for delay.
Yeah logs says that CodePush has issue with performing diff-update. It is strange because is is about the half of your users has installed update successfully.
Could you please clarify have you tried to release one more release? Is behaviour same?
@alexandergoncharov Apologies for the late response!
Could you please clarify have you tried to release one more release?
We are currently setting up another release. I will get back to you once I have more logs.
@krishnagopinath , no worries :)
Just a friendly ping about new logs :)
Hi @krishnagopinath ,
I'm going to close this issue for now as I haven't heard from you in a while unfortunately. Please feel free to reopen it if you have any questions.
Thanks, Alexander
Hey @alexandergoncharov, apologies for the delay!
We were stuck in release hell and hence, could not get back to you. We've got some new information, which may prove to be helpful.
From the time of opening this issue, we've upgraded to cordova-plugin-code-push@1.11.15
and started using cordova-plugin-ionic-webview@2.3.2
.
We added the following logs to the code-push plugin:
With these in place, these were the logs we've obtained from Sentry:
I guess the most important message in that Sentry error is this: Could not get application subdirectory.
. What does that mean? Would that point to something that is problematic in the way we've set this up in our app? Any insights about this would be very helpful!
Hi @krishnagopinath and @alexandergoncharov !
I'm experiencing that same problem on production. Did you guys found out anything new about this?
1 - Only some users experience that problem, it does not happen to all devices. 2 - On my end, the app is not listed as rollback on appcenter, but it doesn't update either. 3 - On the apps that have this proble,It tries to update, but this errors happens, and it tries to update everytime and can't update the app. The only thing that worked was uninstalling the app, and then the latest update worked correctly.
Using the codepush with version 1.11.14 Here's the log I was able to get from using adb logcat:
05-28 12:03:11.873 380 1020 D audio_hw_primary: enable_audio_route: apply and update mixer path: low-latency-playback speaker
05-28 12:03:11.882 19012 19012 D SystemWebChromeClient: file:///android_asset/www/plugins/cordova-plugin-code-push/bin/www/codePushUtil.js: Line 36 : [CodePush] Downloading update
05-28 12:03:11.885 19012 19106 D FileTransfer: download https://codepushupdates.azureedge.net/storagev2/5hrnFjkFnzdiiY7tqnPdINvH0kBUb64bf462-40fc-4863-a51d-622c3964cf0c to file:///data/user/0/com.waybee.apps.student/files/codepush/download/update.zip
05-28 12:03:11.896 19012 19066 D FileTransfer: Download file:https://codepushupdates.azureedge.net/storagev2/5hrnFjkFnzdiiY7tqnPdINvH0kBUb64bf462-40fc-4863-a51d-622c3964cf0c
05-28 12:03:11.871 4785 4785 W Binder_D: type=1400 audit(0.0:379): avc: denied { ioctl } for uid=1000 path="socket:[106830]" dev="sockfs" ino=106830 ioctlcmd=7704 scontext=u:r:system_server:s0 tcontext=u:r:system_server:s0 tclass=unix_stream_socket permissive=0
05-28 12:03:11.871 4785 4785 W Binder_D: type=1400 audit(0.0:380): avc: denied { ioctl } for uid=1000 path="socket:[106830]" dev="sockfs" ino=106830 ioctlcmd=7704 scontext=u:r:system_server:s0 tcontext=u:r:system_server:s0 tclass=unix_stream_socket permissive=0
05-28 12:03:15.163 380 1021 D audio_hw_primary: disable_audio_route: reset and update mixer path: low-latency-playback speaker
05-28 12:03:15.164 380 1021 D audio_hw_primary: disable_snd_device: snd_device(2: speaker)
05-28 12:03:15.180 1804 2504 D NetlinkSocketObserver: NeighborEvent{elapsedMs=1105323, 10.0.1.1, [DCA4CAB9F687], RTM_NEWNEIGH, NUD_REACHABLE}
05-28 12:03:15.409 19012 19066 D FileTransfer: Saved file: file:///data/user/0/com.waybee.apps.student/files/codepush/download/update.zip
05-28 12:03:15.417 19012 19012 D SystemWebChromeClient: file:///android_asset/www/plugins/cordova-plugin-code-push/bin/www/codePushUtil.js: Line 36 : [CodePush] Package download success: {"deploymentKey":"fgPTmCa0aFL_LhTB1C3JWufVcK3srkUIgtu6m","description":"Correcao de bugs e melhorias de seguranca","label":"v4","appVersion":"1.0.1","isMandatory":true,"packageHash":"dc0a0bbc986c1f8accbe4cd280a80e1f4767754302cf8ac25a88bebbb3c626ed","isFirstRun":false,"failedInstall":false,"localPath":"cdvfile://localhost/files/codepush/download/update.zip"}
05-28 12:03:15.418 19012 19012 D SystemWebChromeClient: file:///android_asset/www/plugins/cordova-plugin-code-push/bin/www/codePushUtil.js: Line 36 : [CodePush] Installing update
05-28 12:03:15.507 19012 19066 W Zip : extracting: /data/user/0/com.waybee.apps.student/files/codepush/download/unzipped/hotcodepush.json
05-28 12:03:15.510 19012 19066 W Zip : extracting: /data/user/0/com.waybee.apps.student/files/codepush/download/unzipped/www/static/css/main.css
05-28 12:03:15.540 19012 19066 W Zip : extracting: /data/user/0/com.waybee.apps.student/files/codepush/download/unzipped/www/static/css/main.css.map
05-28 12:03:15.567 19012 19066 W Zip : extracting: /data/user/0/com.waybee.apps.student/files/codepush/download/unzipped/www/static/js/main.js
05-28 12:03:15.645 19012 19066 W Zip : extracting: /data/user/0/com.waybee.apps.student/files/codepush/download/unzipped/www/static/js/main.js.map
05-28 12:03:16.130 19012 19066 W Zip : extracting: /data/user/0/com.waybee.apps.student/files/codepush/download/unzipped/www/static/js/welcome.js
05-28 12:03:16.150 19012 19066 W Zip : extracting: /data/user/0/com.waybee.apps.student/files/codepush/download/unzipped/www/static/js/welcome.js.map
05-28 12:03:16.366 392 578 I ThermalEngine: Sensor:xo_therm_pu2:38000 mC
05-28 12:03:16.377 392 577 I ThermalEngine: Sensor:batt_therm:33000 mC
05-28 12:03:16.727 19012 19012 D SystemWebChromeClient: file:///android_asset/www/plugins/cordova-plugin-code-push/bin/www/codePushUtil.js: Line 41 : [CodePush] Cannot perform diff-update.. StackTrace: Error: Cannot perform diff-update.
05-28 12:03:16.727 19012 19012 D SystemWebChromeClient: at file:///android_asset/www/plugins/cordova-plugin-code-push/bin/www/localPackage.js:360:37
05-28 12:03:16.727 19012 19012 D SystemWebChromeClient: at FileReader.fileReader.onloadend (file:///android_asset/www/plugins/cordova-plugin-code-push/bin/www/fileUtil.js:232:17)
05-28 12:03:16.727 19012 19012 D SystemWebChromeClient: at FileReader.readSuccessCallback (file:///android_asset/www/plugins/cordova-plugin-file/www/FileReader.js:164:18)
05-28 12:03:16.727 19012 19012 D SystemWebChromeClient: at Object.callbackFromNative (file:///android_asset/www/cordova.js:291:58)
05-28 12:03:16.727 19012 19012 D SystemWebChromeClient: at <anonymous>:1:9
05-28 12:03:16.728 19012 19012 D SystemWebChromeClient: file:///android_asset/www/plugins/cordova-plugin-code-push/bin/www/codePushUtil.js: Line 41 : [CodePush] An error occurred during sync. Cannot perform diff-update.. StackTrace: Error: Cannot perform diff-update.
05-28 12:03:16.728 19012 19012 D SystemWebChromeClient: at file:///android_asset/www/plugins/cordova-plugin-code-push/bin/www/localPackage.js:360:37
05-28 12:03:16.728 19012 19012 D SystemWebChromeClient: at FileReader.fileReader.onloadend (file:///android_asset/www/plugins/cordova-plugin-code-push/bin/www/fileUtil.js:232:17)
05-28 12:03:16.728 19012 19012 D SystemWebChromeClient: at FileReader.readSuccessCallback (file:///android_asset/www/plugins/cordova-plugin-file/www/FileReader.js:164:18)
05-28 12:03:16.728 19012 19012 D SystemWebChromeClient: at Object.callbackFromNative (file:///android_asset/www/cordova.js:291:58)
05-28 12:03:16.728 19012 19012 D SystemWebChromeClient: at <anonymous>:1:9
05-28 12:03:16.728 19012 19012 D SystemWebChromeClient: file:///android_asset/www/cordova.js: Line 309 : Error in Success callbackId: File1093340043 : Error: Cannot perform diff-update.
05-28 12:03:16.731 19012 19012 D SystemWebChromeClient: file:///android_asset/www/cordova.js: Line 311 : Uncaught Error: Cannot perform diff-update.
05-28 12:03:16.767 16497 16538 I WorkerManager: dispose()
05-28 12:03:16.768 16497 16538 W ThreadPoolDumper: Queue length for executor EventBus is now 11. Perhaps some tasks are too long, or the pool is too small.
--------- beginning of system
05-28 12:03:20.163 1804 2370 V AlarmManager: sending alarm {ccbb3e5 type 3 *alarm*:com.google.android.gms.auth.authzen.cryptauth.DEVICE_STATE_CHECK_DELAY_COMPLETE}
05-28 12:03:20.174 1804 1804 V AlarmManager: done {ccbb3e5, *alarm*:com.google.android.gms.auth.authzen.cryptauth.DEVICE_STATE_CHECK_DELAY_COMPLETE} [10ms]
05-28 12:03:20.189 3369 19552 I Authzen : [DeviceStateSyncManager] The server is in sync with current state. Nothing to do
05-28 12:03:23.510 1804 2504 D NetlinkSocketObserver: NeighborEvent{elapsedMs=1113653, 10.0.1.1, [DCA4CAB9F687], RTM_NEWNEIGH, NUD_STALE}
Making a diff between the bundle releases, I could'nt find anything much different, except the .DS_Store. I've checked the problem on #199 but it seems to have been fixed already.
Tried to make subsequents updates to a new built app on the staging environment (made 8 updates), but couldn't reproduce the problem.
Description
We've been seeing a huge number of rollbacks occurring in our "Production" deployment of our app. When I say huge, I mean in thousands.
As you can see, we never see any of kind of rollbacks in our Staging environment. Our logs from Sentry suggest show that most of these rollbacks occur because of these error:
Reproduction
We were unable to reproduce this bug in staging, unfortunately :cry:
This could probably be related to #356, because of the following reasons:
Any advice as to get this to happen would be fantastic!
Additional Information
1.11.12
Any help dealing with this problem would be fantastic! :bowing_man: