-
-
Notifications
You must be signed in to change notification settings - Fork 197
Unable to apply changes on device: xxxxxx. Error is: Socket timed out.. #4916
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hi @ValentinMolina500, |
Here is the that out.txt file. Many thanks for the help. |
This issue happen again. The issue come up once i uninstall manually from the android device. I suspect the cli expect there is an instance to communicate with on the mobile phone. So far the solution i found is to change the application Id as mention on the issue #2092 |
I am also facing the same error after updating to Nstivescript 6. My dependencies: |
Hi guys, Thanks for reporting it! Reviewing the provided logs and additional details, I suppose that you've faced an issue with LiveSyncing when the application is closed/uninstalled. I've just merged a pull request with a fix which is available as a Release Candidate ( P.S. The fix should be officially released with the next patch release in a few days. |
@DimitarTachev This issue is still persisting for me after installing the release candidate. I updated NS 6.0 and migrated yesterday, and encountered the same issue in this ticket. I then rolled back to my previous versions which fixed the issue, I tracked this issue and re-updated and migrated with the release candidate but it is still happening. I have attached the log from my build: |
Thanks for providing the logs! Unfortunately, they look fine and we are not able to reproduce such behavior. I even tried with Vue app with the same Webpack compilation warning (v-for without explicit keys). This error could be thrown if your app is crashing on startup (for example, if it has a wrong custom Android activity). In this case, a timeout error is thrown after 60 seconds because your app is not running and we are not able to connect to it. I suggest you check the If you are not able to resolve the issue based on the adb logs, we will need a sample application reproducing the exception. If you are not OK with sharing your app, you could start with a blank Vue app ( |
Thanks for your advice, through looking at the adb logcat I was able to pinpoint an exception occurring inside the inbuilt Android FileProvider (to note, the app was indeed timing out after 60 seconds):
Removing the related lines in our AndroidManifest:
fixed the issue. I'm assuming this isn't a known bug, but if it is do you have any idea how to workaround it for the time being? Thanks again. |
It's part of the AndroidX migration. You have to replace it with: <provider android:name="androidx.core.content.FileProvider" ... Take a look at this thread for more details. |
Fixed. Brilliant. Thank you. |
Unfortunately, none of those suggestions seemed to have helped. Here is some interesting log info of adb logcat: 08-01 18:22:24.161 23963 23963 I FIAM.Headless: Starting InAppMessaging runtime with Instance ID fLYy8gqC79c I hope this helps. |
It seems that your app is crashing because of a Firebase related exception:
I suggest you try updating the nativescript-firebase plugin and open an issue in its GitHub repo if it's still crashing with the latest version. Also, there are a lot of threads discussing such error. |
Migrating to androidx worked for me. Thank you. |
Thanks for the suggestion but unfortunately that did not work for me. I notice my AndroidManifest looks different, here is mine:
|
I'm closing this issue as the error is very common and we've isolated and moved the discussion for your case in the Firebase plugin. Feel free to open a new issue if you have further details for something related to the NativeScript CLI. |
Environment
Provide version numbers for the following components (information can be retrieved by running
tns info
in your project folder or by inspecting thepackage.json
of the project):"@nstudio/nativescript-checkbox": "^1.0.0",
"babel-cli": "^6.26.0",
"babel-preset-react-app": "^3.1.2",
"font-awesome": "^4.7.0",
"g": "^2.0.1",
"nativescript-bottombar": "^3.0.8",
"nativescript-calendar": "^2.1.0",
"nativescript-checkbox": "^3.0.3",
"nativescript-couchbase-plugin": "^0.9.1",
"nativescript-drop-down": "^5.0.2",
"nativescript-floatingactionbutton": "^5.1.0",
"nativescript-image-zoom": "^3.0.3",
"nativescript-material-icons": "^1.0.3",
"nativescript-modal-datetimepicker": "^1.2.0",
"nativescript-nbmaterial-calendar": "^1.0.1",
"nativescript-ng2-fonticon": "^1.3.4",
"nativescript-plugin-firebase": "^9.0.3",
"nativescript-ripple": "^2.2.1",
"nativescript-social-share": "^1.5.2",
"nativescript-theme-core": "^2.0.2",
"nativescript-ui-dataform": "^5.0.0",
"nativescript-ui-listview": "^7.0.1",
"nativescript-ui-sidedrawer": "^7.0.0",
"tns": "^0.2.0",
"tns-core-modules": "^6.1.0-next-2019-07-20-015811-02"
Describe the bug
For some reason, today I tried running my app, and it keeps saying: Unable to apply changes on device: 3852564c33593398. Error is: Socket connection timed out.. I have tried many of the solutions listed here, such as deleting hooks, platforms, package.json, I've tried wiping my repo, and cloning it again from GitHub from a branch I know works but it still fails. I've tried adding the applicationId in app.gradle but still nada. I've tried different cables, phones emulators, and a whole combination of the above steps. I have updated to NativeScript 6 recently, but that was over a week ago, and it was working fine until today. Note that the errors in the log info were present before this issue occurred.
Log Info
Preparing project...
File change detected. Starting incremental webpack compilation...
Starting type checking service...
Using 1 worker with 4096MB memory limit
webpack is watching the files…
Hash: 78a04e3d1fb6a6cc0769
Version: webpack 4.27.1
Time: 4268ms
Built at: 07/30/2019 7:57:21 PM
Asset Size Chunks Chunk Names
bundle.js 1.34 MiB bundle [emitted] bundle
fonts/BentonSans-Bold.otf 24.8 KiB [emitted]
fonts/BentonSans-Medium.otf 24.9 KiB [emitted]
fonts/BentonSans-Regular.otf 24.7 KiB [emitted]
fonts/HelveticaNeueBold.ttf 59.7 KiB [emitted]
fonts/HelveticaNeueCondensedBlack.ttf 73.3 KiB [emitted]
fonts/HelveticaNeueLight.ttf 124 KiB [emitted]
fonts/HelveticaNeueMedium.ttf 119 KiB [emitted]
fonts/MaterialIcons-Regular.ttf 125 KiB [emitted]
fonts/NotoSans-Regular.ttf 389 KiB [emitted]
fonts/OpenSans-Bold.ttf 219 KiB [emitted]
fonts/OpenSans-Regular.ttf 212 KiB [emitted]
fonts/Roboto-Bold.ttf 167 KiB [emitted]
fonts/Roboto-Regular.ttf 168 KiB [emitted]
fonts/fontawesome-webfont.ttf 162 KiB [emitted]
fonts/fontawesome-webfont.woff 95.7 KiB [emitted]
fonts/materialdesignicons-webfont.ttf 534 KiB [emitted]
images/apartments.png 14.8 KiB [emitted]
images/blank-profile-image.png 22.3 KiB [emitted]
images/brian.png 184 KiB [emitted]
images/category-filter.png 294 bytes [emitted]
images/cupboard.jpg 1.14 MiB [emitted]
images/date-filter.png 287 bytes [emitted]
images/drawer-icon.png 318 bytes [emitted]
images/food-and-beverage-category.png 6.88 KiB [emitted]
images/image.jpg 227 KiB [emitted]
images/lois.png 77.5 KiB [emitted]
images/owe-indicator.png 302 bytes [emitted]
images/owed-indicator.png 302 bytes [emitted]
images/pat.png 171 KiB [emitted]
images/peter.png 446 KiB [emitted]
images/total-indicator.png 302 bytes [emitted]
images/trioLogo.png 195 KiB [emitted]
package.json 157 bytes [emitted]
runtime.js 71.4 KiB runtime [emitted] runtime
tns-java-classes.js 0 bytes [emitted]
vendor.js 4.8 MiB vendor [emitted] vendor
viewmodels/default-profile-picture/default_picture.png 1.25 KiB [emitted]
views/home/app-page/app-images/plusIcon.png 1.09 KiB [emitted]
views/home/app-page/choose-mentor-page/mentor/images/mentorIcon.jpg 21.3 KiB [emitted]
views/home/settings-page/settings-images/settings.png 318 bytes [emitted]
views/login/login_images/Handshake-Home-Page-Button.png 70.3 KiB [emitted]
views/login/login_images/WSU-Apartments-sign.jpg 78.8 KiB [emitted]
views/login/login_images/fafsa.jpg 10 KiB [emitted]
views/login/login_images/logo.png 195 KiB [emitted]
views/login/login_images/maxresdefault.jpg 114 KiB [emitted]
views/login/login_images/mind-human-brain-thought-vector-of-the-brain-gear.jpg 87.8 KiB [emitted]
views/login/login_images/trio-logo.png 66.4 KiB [emitted]
views/login/login_images/wsu-cougarhead.png 10.5 KiB [emitted]
views/login/login_images/wsutc.png 7.28 KiB [emitted]
Entrypoint bundle = runtime.js vendor.js bundle.js
[./ sync ^./app.(css|scss|less|sass)$] . sync nonrecursive ^./app.(css|scss|less|sass)$ 174 bytes {bundle} [built]
[./ sync recursive (?<!\bApp_Resources\b.).(xml|css|js|(?<!.d.)ts|(?<!\b_[\w-].)scss)$] . sync (?<!\bApp_Resources\b.).(xml|css|js|(?<!.d.)ts|(?<!\b_[\w-].)scss)$ 6.03 KiB {bundle} [built]
[./app-root-viewmodel.ts] 1 KiB {bundle} [built]
[./app-root.ts] 421 bytes {bundle} [optional] [built]
[./app-root.xml] 825 bytes {bundle} [optional] [built]
[./app.css] 4.83 KiB {bundle} [optional] [built]
[./app.ts] 1.95 KiB {bundle} [built]
[./constants/advisorDatabaseConstants.js] 1.24 KiB {bundle} [optional] [built]
[./constants/advisorDatabaseConstants.ts] 303 bytes {bundle} [optional] [built]
[./constants/appointmentConstants.js] 593 bytes {bundle} [optional] [built]
[./constants/appointmentConstants.ts] 286 bytes {bundle} [optional] [built]
[./constants/constants.ts] 404 bytes {bundle} [built]
[./material-design-icons.css] 52.7 KiB {bundle} [optional] [built]
[./utils/couchbase.js] 3.92 KiB {bundle} [optional] [built]
[./utils/firebase.ts] 12.2 KiB {bundle} [built]
+ 339 hidden modules
ERROR in D:/GitHub/WSUTC_TRIOApp/app/views/register/register-view-model.ts
ERROR in D:/GitHub/WSUTC_TRIOApp/app/views/register/register-view-model.ts(8,40):
TS2305: Module '"../../../../../GitHub/WSUTC_TRIOApp/node_modules/tns-core-modules/ui/frame/frame"' has no exported member 'stack'.
ERROR in D:/GitHub/WSUTC_TRIOApp/app/views/register/register-view-model.ts
ERROR in D:/GitHub/WSUTC_TRIOApp/app/views/register/register-view-model.ts(12,15):
TS2749: 'UserViewModel' refers to a value, but is being used as a type here.
ERROR in D:/GitHub/WSUTC_TRIOApp/app/views/register/register-view-model.ts
ERROR in D:/GitHub/WSUTC_TRIOApp/app/views/register/register-view-model.ts(13,18):
TS2749: 'myDialogs' refers to a value, but is being used as a type here.
ERROR in D:/GitHub/WSUTC_TRIOApp/app/views/resetpassword/reset-view-model.ts
ERROR in D:/GitHub/WSUTC_TRIOApp/app/views/resetpassword/reset-view-model.ts(6,15):
TS2749: 'UserViewModel' refers to a value, but is being used as a type here.
ERROR in D:/GitHub/WSUTC_TRIOApp/app/views/resetpassword/reset-view-model.ts
ERROR in D:/GitHub/WSUTC_TRIOApp/app/views/resetpassword/reset-view-model.ts(8,18):
TS2749: 'myDialogs' refers to a value, but is being used as a type here.
Webpack compilation complete. Watching for file changes.
Webpack build done!
nativescript-plugin-firebase: D:\GitHub\WSUTC_TRIOApp\platforms\android.pluginfirebaseinfo not found, forcing prepare!
nativescript-plugin-firebase: running release build or change in environment detected, forcing prepare!
Built aar for nativescript-plugin-firebase
Chokidar raised event change for D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-ripple\platforms\android\include.gradle.
Built aar for nativescript-nbmaterial-commons
Chokidar raised event change for D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-nbmaterial-commons\platforms\android\include.gradle.
nativescript-plugin-firebase: D:\GitHub\WSUTC_TRIOApp\platforms\android.pluginfirebaseinfo not found, forcing prepare!
nativescript-plugin-firebase: running release build or change in environment detected, forcing prepare!
Project successfully prepared (android)
Configure firebase
Copy D:\GitHub\WSUTC_TRIOApp\app\App_Resources\Android\google-services.json to D:\GitHub\WSUTC_TRIOApp\platforms\android\app\google-services.json.
Building project...
Gradle build...
+ setting applicationId
+ applying user-defined configuration from D:\GitHub\WSUTC_TRIOApp\app\App_Resources\Android\app.gradle
+ using andorid X library androidx.legacy:legacy-support-v4:1.0.0
+ adding nativescript runtime package dependency: nativescript-optimized-with-inspector
+ adding aar plugin dependency: D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-calendar\platforms\android\nativescript_calendar.aar
+ adding aar plugin dependency: D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-couchbase-plugin\platforms\android\fancycouchbase-release.aar
+ adding aar plugin dependency: D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-plugin-firebase\platforms\android\firebase-release.aar
+ adding aar plugin dependency: D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-plugin-firebase\platforms\android\nativescript_plugin_firebase.aar
+ adding aar plugin dependency: D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-social-share\platforms\android\nativescript_social_share.aar
+ adding aar plugin dependency: D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-ui-dataform\platforms\android\TNSDataForm-release.aar
+ adding aar plugin dependency: D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-ui-listview\platforms\android\TNSListView-release.aar
+ adding aar plugin dependency: D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-ui-sidedrawer\platforms\android\TNSSideDrawer-release.aar
+ adding aar plugin dependency: D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-nbmaterial-commons\platforms\android\nativescript_nbmaterial_commons.aar
+ adding aar plugin dependency: D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-ui-autocomplete\platforms\android\TNSAutoComplete-release.aar
+ adding aar plugin dependency: D:\GitHub\WSUTC_TRIOApp\node_modules\nativescript-ui-core\platforms\android\TNSCore-release.aar
+ adding aar plugin dependency: D:\GitHub\WSUTC_TRIOApp\node_modules\tns-core-modules-widgets\platforms\android\widgets-release.aar
registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection)
registerResGeneratingTask is deprecated, use registerGeneratedResFolders(FileCollection)
To Reproduce
Run "tns run android" in the terminal.
Expected behavior
The application to run correctly.
The text was updated successfully, but these errors were encountered: