{ "id": "153578", "key": "TIMOB-20088", "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": "2015-12-03T00:32:16.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "qe-5.1.2" ], "versions": [ { "id": "17072", "name": "Release 5.1.2", "archived": false, "released": true, "releaseDate": "2016-01-12" }, { "id": "17532", "name": "Release 5.1.1", "archived": false, "released": true, "releaseDate": "2015-11-24" } ], "issuelinks": [ { "id": "50057", "type": { "id": "10122", "name": "Gantt: start-finish", "inward": "is triggered by", "outward": "is triggering" }, "outwardIssue": { "id": "153582", "key": "MOD-2169", "fields": { "summary": "Fixed some bugs and cosmetic issues with ti.cloud sample app", "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" } }, "priority": { "name": "High", "id": "2" }, "issuetype": { "id": "4", "description": "An improvement or enhancement to an existing feature or task.", "name": "Improvement", "subtask": false } } } }, { "id": "50056", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "149855", "key": "MOD-2138", "fields": { "summary": "ti.cloud: Example app crashes on iOS and Android with 4.1.0.GA due to being unable to find files", "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" } }, "priority": { "name": "High", "id": "2" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": null, "updated": "2018-02-28T19:55:45.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": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "*Details:* If you have a CommonJS module in a \"windows\" folder, then you cannot require the CommonJS module.\r\n\r\n*Notes:*\r\n* This is not a regression from SDK 5.1.1.GA.\r\n* This occurs with both Alloy and Titanium classic projects.\r\n* To workaround this issue, do not use \"windows\" to store CommonJS modules.\r\n\r\n*Steps to reproduce:*\r\n# Create an Alloy or Titanium class project\r\n** If you created an Alloy project:\r\n### Download and unzip {{lib.zip}} into the {{app}} folder\r\n### In {{app/controllers/index.js}}, replace the code with:\r\n{code}\r\nfunction doClick(e) {\r\n alert($.label.text);\r\n \r\n var monkey = require('windows/test').monkey;\r\n Ti.API.info(monkey());\r\n}\r\n\r\n$.index.open();\r\n{code}\r\n** If you created a Titanium project:\r\n### Download and unzip {{windows.zip}} into the {{Resources}} folder\r\n### In {{app.js}}, add the following code after creating {{label1}}:\r\n{code}\r\nlabel1.addEventListener('click', function(evt) {\r\n\tvar monkey = require('/windows/test').monkey;\r\n\tTi.API.info(monkey());\r\n});\r\n{code}\r\n# Save your changes and install to iOS simulator or Android emulator\r\n# When the app launches, click on label that appears\r\n\r\n*Actual:* On both iOS simulator and Android emulator, using either Alloy or Titanium projects, the CommonJS module cannot be found; see attachments.\r\n\r\n*Expected:* On both iOS simulator and Android emulator, using either Alloy or Titanium projects, the CommonJS module should be found i.e. you should be able to use \"windows\" folder to store your CommonJS modules.\r\n", "attachment": [ { "id": "57661", "filename": "android_emulator.png", "author": { "name": "wluu", "key": "wluu", "displayName": "Wilson Luu", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-12-03T00:32:08.000+0000", "size": 73760, "mimeType": "image/png" }, { "id": "57660", "filename": "ios_simulator.png", "author": { "name": "wluu", "key": "wluu", "displayName": "Wilson Luu", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-12-03T00:32:08.000+0000", "size": 28962, "mimeType": "image/png" }, { "id": "57663", "filename": "lib.zip", "author": { "name": "wluu", "key": "wluu", "displayName": "Wilson Luu", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-12-03T00:20:40.000+0000", "size": 471, "mimeType": "application/zip" }, { "id": "57662", "filename": "windows.zip", "author": { "name": "wluu", "key": "wluu", "displayName": "Wilson Luu", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2015-12-03T00:21:09.000+0000", "size": 343, "mimeType": "application/zip" } ], "flagged": false, "summary": "If you have a CommonJS module in a \"windows\" folder, then you cannot require the CommonJS module", "creator": { "name": "wluu", "key": "wluu", "displayName": "Wilson Luu", "active": false, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "wluu", "key": "wluu", "displayName": "Wilson Luu", "active": false, "timeZone": "America/Los_Angeles" }, "environment": "Appcelerator Studio, build: 4.4.0.201511241829\r\nAppc CLI NPM: 4.2.2\r\nAppc CLI Core: 5.1.0\r\nArrow: 1.3.22\r\nSDK: 5.1.1.GA, 5.1.2.v20151202061227\r\nNode: v4.2.2\r\nOS: El Capitan (10.11.1)\r\nXcode: 7.1.1\r\nDevices: iphone simulator (9.1), Nexus 6 (6.0)\r\n", "comment": { "comments": [], "maxResults": 0, "total": 0, "startAt": 0 } } }