NativeScript / NativeScript/nativescript-cli

Failure to start LiveSync causes CLI to hang

Open
#3,375 0 comments 0 reactions 1 assignee View on GitHub

@Mitko-Kerezov is already working on this.

Since Feb 19, 2018.

bug livesync reproducible run severity: low to-be-checked
Dominant language
JavaScript
Stars
1.1k
Forks
204
Avg merge
1d 9h
Merged PRs (30d)
8

Description

The problem

Whenever starting LiveSync on a new project if LiveSync is unable to start (for example a TypeScript error is present) then CLI tries to exit, but hangs because it has child processes attached to it.

Steps to reproduce

On a Unix OS:

  1. tns create myApp --tsc
  2. cd myApp
  3. echo asd >> app/app.ts // this will cause the transpile error
  4. tns run android // could be ios just as well

At this point CLI fails to start LiveSync, because there is a syntax error in the main TypeScript file and the message Unable to apply changes on device: XXXXXXXXXXXXXX. Error is: TypeScript compiler failed with exit code 1. is displayed, however the process does not finish and the user is forced to break execution with Ctrl-C.

This issue is caused by the various child processes that CLI spawns like the one for communication with iOS devices or analytics.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.