{ "id": "136588", "key": "ALOY-1138", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "11113", "key": "ALOY", "name": "Alloy", "projectCategory": { "id": "10400", "description": "Tools for developing applications", "name": "Tooling" } }, "fixVersions": [ { "id": "16596", "name": "Alloy 1.6.0", "archived": false, "released": true, "releaseDate": "2015-05-21" }, { "id": "16692", "name": "Alloy 1.7.0", "archived": false, "released": true, "releaseDate": "2015-07-22" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2014-10-07T01:32:11.000+0000", "created": "2014-09-15T16:12:54.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "usability" ], "versions": [ { "id": "15909", "description": "Alloy 1.5.0", "name": "Alloy 1.5.0", "archived": false, "released": true, "releaseDate": "2014-09-29" }, { "id": "16389", "name": "Alloy 1.4.1", "archived": false, "released": true, "releaseDate": "2014-07-28" } ], "issuelinks": [], "assignee": { "name": "skypanther", "key": "skypanther", "displayName": "Tim Poulsen", "active": true, "timeZone": "America/New_York" }, "updated": "2015-01-13T14:42:15.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "13602", "name": "Appcelerator Studio", "description": "Appcelerator Studio specific issues" }, { "id": "13604", "name": "Tooling", "description": "Items related to Alloy tooling and workflow" } ], "description": "h5. Problem description\r\nIf no config.json file is present, creating a new Widget returns an error.\r\n\r\nh5. Steps\r\n1. Create a new Alloy project\r\n2. Delete config.json file in the root project folder\r\n3. From Appcelerator Studio, left click and create a new Widget\r\n\r\nResult: a problem occurred creating a new widget.\r\nWidget folder is created but config.json file is not found and an error is thrown.\r\n{code}\r\nfs.js:427\r\n return binding.open(pathModule._makeLong(path), stringToFlags(flags), mode);\r\n ^\r\nError: ENOENT, no such file or directory '/usr/local/lib/node_modules/alloy/Alloy/template/config.json'\r\n at Object.fs.openSync (fs.js:427:18)\r\n at Object.fs.readFileSync (fs.js:284:15)\r\n at module.exports (/usr/local/lib/node_modules/alloy/Alloy/commands/generate/targets/widget.js:50:19)\r\n at generate (/usr/local/lib/node_modules/alloy/Alloy/commands/generate/index.js:37:34)\r\n at Object. (/usr/local/lib/node_modules/alloy/Alloy/alloy.js:100:46)\r\n at Module._compile (module.js:456:26)\r\n at Object.Module._extensions..js (module.js:474:10)\r\n at Module.load (module.js:356:32)\r\n at Function.Module._load (module.js:312:12)\r\n at Module.require (module.js:364:17)\r\n at require (module.js:380:17)\r\n at Object. (/usr/local/lib/node_modules/alloy/bin/alloy:3:1)\r\n at Module._compile (module.js:456:26)\r\n at Object.Module._extensions..js (module.js:474:10)\r\n at Module.load (module.js:356:32)\r\n at Function.Module._load (module.js:312:12)\r\n at Function.Module.runMain (module.js:497:10)\r\n at startup (node.js:119:16)\r\n at node.js:901:3\r\n{code}\r\n\r\nIdeal result would probably be to automatically create a default config.json file and add in there the informations regarding the new created Widget.\r\n\r\nIf config.json file is removed, then, in order to create a new Widget, the user has to re-create manually a new config.json file just including : {{ {} }}\r\n\r\n\r\nh5. Note\r\nNot a regression. \r\n", "attachment": [], "flagged": false, "summary": "Error creating a new Widget from Studio if config.json is not present", "creator": { "name": "fcasali", "key": "fcasali", "displayName": "Federico Casali", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "fcasali", "key": "fcasali", "displayName": "Federico Casali", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "TiSDK 3.4.0.v20140913174915 & 3.3.1.GA\r\nAppcelerator Studio 3.4.0.201409131030 & 3.3.0.201407111535\r\nCLI 3.4.0-rc3 & 3.3.0.GA\r\nAlloy 1.5.0-rc2 & Alloy 1.4.1.GA\r\nXcode6 GM", "closedSprints": [ { "id": 228, "state": "closed", "name": "2014 Sprint 20 Alloy", "startDate": "2014-09-29T13:30:47.322Z", "endDate": "2014-10-13T13:30:00.000Z", "completeDate": "2014-10-13T18:08:16.541Z", "originBoardId": 124 } ], "comment": { "comments": [ { "id": "326586", "author": { "name": "skypanther", "key": "skypanther", "displayName": "Tim Poulsen", "active": true, "timeZone": "America/New_York" }, "body": "PR: https://github.com/appcelerator/alloy/pull/582\r\n\r\nFunctional test:\r\n\r\n1. Create a new alloy project\r\n2. Delete the app/config.json file\r\n3. At the command line, from the project's directory, enter {{alloy generate widget foo}}. The widget should be generated without errors\r\n4. Confirm that config.json has been created, and the widget dependency added to it", "updateAuthor": { "name": "skypanther", "key": "skypanther", "displayName": "Tim Poulsen", "active": true, "timeZone": "America/New_York" }, "created": "2014-10-01T15:38:35.000+0000", "updated": "2014-10-01T15:38:35.000+0000" }, { "id": "327103", "author": { "name": "fmiao", "key": "fmiao", "displayName": "Feon Sua Xin Miao", "active": true, "timeZone": "America/Vancouver" }, "body": "PR merged.", "updateAuthor": { "name": "fmiao", "key": "fmiao", "displayName": "Feon Sua Xin Miao", "active": true, "timeZone": "America/Vancouver" }, "created": "2014-10-07T01:32:11.000+0000", "updated": "2014-10-07T01:32:11.000+0000" }, { "id": "327166", "author": { "name": "fcasali", "key": "fcasali", "displayName": "Federico Casali", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Verified fixed.\r\n\r\nTiSDK 3.4.1.v20141007094537\r\nAppcelerator Studio 3.4.1.201409191405\r\nCLI 3.4.0.GA\r\nAlloy 1.6.0-dev\r\n\r\nClosing.", "updateAuthor": { "name": "fcasali", "key": "fcasali", "displayName": "Federico Casali", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2014-10-07T17:54:46.000+0000", "updated": "2014-10-07T17:54:46.000+0000" }, { "id": "338872", "author": { "name": "skypanther", "key": "skypanther", "displayName": "Tim Poulsen", "active": true, "timeZone": "America/New_York" }, "body": "Backport to 1_6_X https://github.com/appcelerator/alloy/pull/656", "updateAuthor": { "name": "skypanther", "key": "skypanther", "displayName": "Tim Poulsen", "active": true, "timeZone": "America/New_York" }, "created": "2015-01-13T14:41:21.000+0000", "updated": "2015-01-13T14:41:21.000+0000" } ], "maxResults": 4, "total": 4, "startAt": 0 } } }