Project: titanium
Issue TIMOB-17691: CLI: Running "ti build -p iOS -T simulator --retina" command throws error 'defaultIosVersion is not defined'
Description: Running "ti build -p iOS -T simulator --retina" command throws an error instead of launching the application on retina simulator. The same error is thrown with two other iOS flags like --tall and --sim-64bit respectively. The flags were working successfully with Titanium SDK build 3.4.0.v20140912164913 and CLI 3.4.0-rc3 with tiapp.xml sdk set to 3.4.0.v20140912164913. The problem seems to be with Titanium SDK build 3.4.0.v20140913174915 and CLI 3.4.0-rc3 with tiapp.xml sdk set to 3.4.0.v20140913174915. This is a regression.The commands were working with CLI 3.3.0 and titanium SDK 3.3.0.GA. STEPS TO REPRODUCE:- 1. Open a terminal window 2. Create a project and you have to "cd" to this project to be able to run command "build". 3. Run "ti build -p iOS -T simulator --retina 4. Run "ti build -p iOS -T simulator --tall 5. Run "ti build -p iOS -T simulator --sim-64bit EXPECTED RESULT 3. The project should build successfully and get launched on retina simulator. 4. The project should build successfully and get launched on tall simulator. 5. The project should build successfully and get launched on 64 bits simulator. ACTUAL RESULT 3. The command throws an error when ran with --retina flag instead of building the project and launching it. 4. The command throws an error when ran with --tall flag instead of building the project and launching it. 5. The command throws an error when ran with --sim-64bit flag instead of building the project and launching it. The following error is thrown on the terminal with all this commands. {code} KAGRAWAL-MBP:sampleapplication kagrawal$ ti build -p ios -T simulator --retina Titanium Command-Line Interface, CLI version 3.4.0-rc3, Titanium SDK version 3.4.0.v20140913174915 Copyright (c) 2012-2014, Appcelerator, Inc. All Rights Reserved. Please report bugs to http://jira.appcelerator.org/ /usr/local/lib/node_modules/titanium/node_modules/longjohn/dist/longjohn.js:185 throw e; ^ ReferenceError: defaultIosVersion is not defined at iOSBuilder.getDeviceInfo (/Users/kagrawal/Library/Application Support/Titanium/mobilesdk/osx/3.4.0.v20140913174915/iphone/cli/commands/_build.js:168:64) at callback.options.device-id.verifyIfRequired (/Users/kagrawal/Library/Application Support/Titanium/mobilesdk/osx/3.4.0.v20140913174915/iphone/cli/commands/_build.js:558:24) at CLI. (/usr/local/lib/node_modules/titanium/lib/cli.js:606:16) at /usr/local/lib/node_modules/titanium/node_modules/async/lib/async.js:551:21 at /usr/local/lib/node_modules/titanium/node_modules/async/lib/async.js:227:13 at iterate (/usr/local/lib/node_modules/titanium/node_modules/async/lib/async.js:134:13) at /usr/local/lib/node_modules/titanium/node_modules/async/lib/async.js:145:25 at /usr/local/lib/node_modules/titanium/node_modules/async/lib/async.js:229:17 at /usr/local/lib/node_modules/titanium/node_modules/async/lib/async.js:556:34 at CLI. (/usr/local/lib/node_modules/titanium/lib/cli.js:664:9) --------------------------------------------- at exports.execFile (child_process.js:691:9) at exports.exec (child_process.js:578:18) at /Users/kagrawal/Library/Application Support/Titanium/mobilesdk/osx/3.4.0.v20140913174915/node_modules/node-appc/lib/environ.js:251:3 at /Users/kagrawal/Library/Application Support/Titanium/mobilesdk/osx/3.4.0.v20140913174915/node_modules/node-appc/node_modules/async/lib/async.js:254:17 at /Users/kagrawal/Library/Application Support/Titanium/mobilesdk/osx/3.4.0.v20140913174915/node_modules/node-appc/node_modules/async/lib/async.js:157:25 at /Users/kagrawal/Library/Application Support/Titanium/mobilesdk/osx/3.4.0.v20140913174915/node_modules/node-appc/node_modules/async/lib/async.js:251:21 at /Users/kagrawal/Library/Application Support/Titanium/mobilesdk/osx/3.4.0.v20140913174915/node_modules/node-appc/node_modules/async/lib/async.js:615:34 at /Users/kagrawal/Library/Application Support/Titanium/mobilesdk/osx/3.4.0.v20140913174915/node_modules/node-appc/lib/environ.js:218:7 {code}
Story points: 1