Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-19698] Windows: CLI doesn't exit like on Mac when running into a parse error

GitHub Issuen/a
TypeBug
PriorityNone
StatusClosed
ResolutionFixed
Resolution Date2015-11-03T14:19:20.000+0000
Affected Version/sRelease 5.0.2
Fix Version/sRelease 5.1.0
ComponentsWindows
Labelsn/a
ReporterFokke Zandbergen
AssigneeKota Iguchi
Created2015-10-09T11:48:31.000+0000
Updated2015-11-04T18:30:52.000+0000

Description

On Mac OS X, when the CLI runs into a JS parse error it will exit. On Windows it does not and you have to manually kill the process. *Sample*
var win = Ti.UI.createWindow(backgroundColor:'#FFF'});
win.open();

Attachments

FileDateSize
Screen Shot 2015-10-09 at 13.43.07.png2015-10-09T11:48:28.000+000018105
Screen Shot 2015-10-09 at 13.43.13.png2015-10-09T11:48:29.000+000035774

Comments

  1. Kota Iguchi 2015-10-29

    I'm using Windows PowerShell but this does not happen to me. [~fokkezb] Did you use PowerShell?
  2. Fokke Zandbergen 2015-10-29

    I just tested it again and still have it. Windows 8.1 Enterprise using PowerShell and:
       ti build -p windows -C 8-1-1 -I 00000000-0000-1000-8000-000000000000
       
  3. Kota Iguchi 2015-10-29

    Got it. Looks like it's because it stopped while launching emulator. working on it.
  4. Kota Iguchi 2015-10-30

    https://github.com/appcelerator/titanium_mobile_windows/pull/460
  5. Ewan Harris 2015-11-04

    Verified using: Windows 10 Pro Appc Core: 5.1.0-42 Appc NPM: 4.2.1 Ti SDK: 5.1.0.v20151104073721 When running into a parse error the CLI now exits
       [ERROR] Failed to parse C:\Users\ewanh\Documents\Appcelerator_Studio_Workspace\classicApp\Resources\app.js
       Unexpected character '#' [line 2, column 31]
       
           Titanium.UI.setBackgroundColor(#000');
           -------------------------------^
       
       
       [ERROR] An error occurred during build after 3s 209ms
       [ERROR] Failed to parse JavaScript files.
       ERROR  | ti run exited with error code 1
       
    Closing ticket

JSON Source