{ "id": "175850", "key": "TIMOB-28266", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [], "resolution": null, "resolutiondate": null, "created": "2020-12-03T11:04:59.000+0000", "priority": { "name": "None", "id": "6" }, "labels": [], "versions": [ { "id": "21052", "description": "", "name": "Release 9.3.0", "archived": false, "released": true, "releaseDate": "2020-12-14" }, { "id": "21129", "name": "Release 9.2.2", "archived": false, "released": true, "releaseDate": "2020-10-29" } ], "issuelinks": [], "assignee": { "name": "eharris", "key": "eharris", "displayName": "Ewan Harris", "active": true, "timeZone": "Europe/Dublin" }, "updated": "2020-12-03T11:05:09.000+0000", "status": { "description": "The issue is open and ready for the assignee to start work on it.", "name": "Open", "id": "1", "statusCategory": { "id": 2, "key": "new", "colorName": "blue-gray", "name": "To Do" } }, "components": [ { "id": "10202", "name": "Android", "description": "Android Platform" }, { "id": "13103", "name": "CLI", "description": "Node-based command line interface" } ], "description": "h5.Description\r\n\r\nWhen building to a specific Android device (i.e. {{appc run -p android -T device -C foo}}) and no device is attached the following error will occur, I think this might be down to calling callback in the device-id prompt without any values\r\n\r\n{code}\r\nTypeError: Cannot read property 'once' of undefined\r\n at wireupPrePrompt (/Users/awam/git/titanium/lib/cli.js:421:12)\r\n at /Users/awam/git/titanium/lib/cli.js:590:21\r\n at /Users/awam/Library/Application Support/Titanium/mobilesdk/osx/9.3.0.v20201125050632/android/cli/commands/_build.js:421:17\r\n at AndroidBuilder.findTargetDevices (/Users/awam/Library/Application Support/Titanium/mobilesdk/osx/9.3.0.v20201125050632/android/cli/commands/_build.js:157:12)\r\n at prompt (/Users/awam/Library/Application Support/Titanium/mobilesdk/osx/9.3.0.v20201125050632/android/cli/commands/_build.js:378:8)\r\n at Object.opt.prompt (/Users/awam/git/titanium/lib/cli.js:589:11)\r\n at /Users/awam/git/titanium/lib/cli.js:847:9\r\n at /Users/awam/git/titanium/node_modules/async/dist/async.js:4096:9\r\n at Object.process (/Users/awam/git/titanium/node_modules/async/dist/async.js:2344:17)\r\n at /Users/awam/git/titanium/node_modules/async/dist/async.js:2252:19\r\n{code}\r\n\r\nh5.Steps to reproduce\r\n\r\n1. Make sure no devices are attached\r\n2. Build a project with {{appc run -p android -T device -C foo}}\r\n\r\nh5.Actual\r\n\r\nError is thrown\r\n\r\nh5.Expected\r\n\r\nNo error", "attachment": [], "flagged": false, "summary": "CLI: Building to Android with target device and a device ID results in an error", "creator": { "name": "eharris", "key": "eharris", "displayName": "Ewan Harris", "active": true, "timeZone": "Europe/Dublin" }, "subtasks": [], "reporter": { "name": "eharris", "key": "eharris", "displayName": "Ewan Harris", "active": true, "timeZone": "Europe/Dublin" }, "environment": null, "comment": { "comments": [], "maxResults": 0, "total": 0, "startAt": 0 } } }