Nativescript-cli: Debug on device does not sync file changes

Created on 7 Feb 2017  路  18Comments  路  Source: NativeScript/nativescript-cli

_From @bnussey on February 3, 2017 20:16_

When using debug mode on device (works as expected on emulator), it does not sync new files with the following error message:

Unable to sync files. Error is: Unable to kill the application.

This results in having to re-run the debug command
Here's full logs:

Executing before-prepare hook from /Users/blake/Documents/ns/app/hooks/before-prepare/nativescript-dev-typescript.js
Preparing project...
Project successfully prepared (iOS)
Executing after-prepare hook from /Users/blake/Documents/ns/app/hooks/after-prepare/nativescript-unit-test-runner.js
Transferring project files...
Successfully transferred asset-manager.models.js.
Successfully synced application com.stageme.app on device 1a33b375679bbb440fb6dbfcad31ea28bb1ed8af.

Frontend socket closed!
Unable to sync files. Error is: Unable to kill the application.

_Copied from original issue: NativeScript/NativeScript#3575_

bug

Most helpful comment

@bnussey can you try CLI's @next version and see if the issue is still reproducible?
In order to install it, you should execute:

$ npm i -g nativescript@next

Thanks in advance for your help.

All 18 comments

_From @mounirka on February 4, 2017 23:58_

Hi @bnussey are you using the command tns run android ?

_From @tsonevn on February 6, 2017 12:40_

Hi @bnussey,

I reviewed your case, however, was unable to reproduce such a problem. Regard to that, could you provide some more info about your problem and exact steps, which you are following?
I tested your case tns run <platform_name>, which will automatically start livesync and it seems to work as expected.

Regards,
@tsonevn

_From @bnussey on February 6, 2017 19:12_

Hey all,

Sorry, left that key bit of information out. The command I use is tns run debug ios

@bnussey the possible commands are:

  • tns run ios
  • tns debug ios

There is no tns run debug ios

Hey @Plamen5kov sorry im talking about tns debug ios

@bnussey I couldn't reproduce your project. What I did:

tns create cliapp && cd cliapp
tns debug ios
// change some files in main-view-model.js

Did you do this specifically on the device @Plamen5kov ? it works fine on emulator, but not device.

@bnussey I managed to reproduce it once. Problem is, it might take some time to manage to find what the reason behind the crash is, since it isn't reproduced every time. I'm investigating further.

Great thanks @Plamen5kov

Hey @bnussey , can you try CLI's @next version and see if the error is still reproducible?
Just install the next version via:

npm i -g nativescript@next

and try again.

I'm looking forward to hearing from you.

I can reproduce this on my machine with CLI version 3.0.0-2017.3.23.1

Still getting this issue and able to reproduce it freely when on device...

Am getting this error with tns version 2.5.0 everytime I try tns run ios.

Interestingly though tns livesync ios works perfectly for the same project...!

Note - After a few successes - Now tns livesync ios is also not working!!

Any updates on this? Still seems to be a problem.

@bnussey can you try CLI's @next version and see if the issue is still reproducible?
In order to install it, you should execute:

$ npm i -g nativescript@next

Thanks in advance for your help.

Hey @rosen-vladimirov can report it fixes it.

Hey @etabakov I am now getting this on run for the emulator:

Unable to sync files. Error is: Multiple errors were thrown:
Error Command failed: xcrun simctl launch 2006D8E4-F732-46D3-91E2-BB214E973318 com.stageme.app
An error was encountered processing the command (domain=FBSOpenApplicationServiceErrorDomain, code=3):
The request to open "com.stageme.app" failed.
The process did launch, but has since exited or crashed.
 while executing xcrun simctl launch 2006D8E4-F732-46D3-91E2-BB214E973318 

Looks like it might be back...

Unable to sync files. Error is: Could not stop application
Was this page helpful?
0 / 5 - 0 ratings

Related issues

kefahB picture kefahB  路  3Comments

charsleysa picture charsleysa  路  3Comments

Anilinfo2015 picture Anilinfo2015  路  3Comments

erjdriver picture erjdriver  路  3Comments

ZMW9 picture ZMW9  路  3Comments