{ "id": "78739", "key": "TIMOB-4887", "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": { "id": "7", "description": "", "name": "Invalid" }, "resolutiondate": "2017-07-10T22:22:50.000+0000", "created": "2011-08-03T17:49:51.000+0000", "priority": { "name": "Low", "id": "4" }, "labels": [ "integrity", "scout" ], "versions": [ { "id": "11570", "description": "", "name": "Release 1.7.2", "archived": true, "released": true, "releaseDate": "2011-07-21" } ], "issuelinks": [], "assignee": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2017-07-10T22:22:50.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": "10202", "name": "Android", "description": "Android Platform" } ], "description": "Description:\r\nWhile evaluating some techniques for porting existing test cases into integrity, Vasyl on the Integrity team gave us some code to illustrate a simple form of the method the integrity harness uses to open .js files. This code works on iOS devices and the iOS simulator, but crashes when run on Android device/emulator. The crash occurs when clicking the button to open a new window:\r\n\r\nvar win = Ti.UI.createWindow({backgroundColor: '#fff'});\r\n\r\n// Place a .js file into applicationDataDirectory\r\nvar file = Titanium.Filesystem.getFile(\r\n\tTitanium.Filesystem.applicationDataDirectory,\r\n\t'script.js'\r\n);\r\n\r\nfile.write(\"Ti.UI.currentWindow.add(\\\r\n\tTi.UI.createLabel({\\\r\n\t\ttext:'Some text',\\\r\n\t\ttop: 100,\\\r\n\t\tleft: 50,\\\r\n\t\twidth: 100,\\\r\n\t\theight:50\\\r\n\t})\\\r\n);\");\r\n\r\nvar btn = Titanium.UI.createButton({\r\n title: 'Next test',\r\n width: 100,\r\n height: 40,\r\n left: 50\r\n});\r\n\r\nbtn.addEventListener('click', function() {\r\n // Open window with new context\r\n Ti.UI.createWindow({\r\n url: file.nativePath\r\n }).open();\r\n});\r\n\r\nwin.add(btn);\r\nwin.open();\r\n\r\nSteps to Reproduce:\r\n1) Create a new mobile project with 1.7.2 release\r\n2) Paste code above into app.js\r\n3) Run in emulator or run on device\r\n4) Click the \"Next Test\" button\r\n\r\nResult:\r\nThe application crashes. See log for details.\r\n\r\nExpected result:\r\nThe text \"Some text\" appears.\r\n\r\nNotes: Does not occur on iOS", "attachment": [ { "id": "22215", "filename": "logcat.txt", "author": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-08-03T17:49:51.000+0000", "size": 6115, "mimeType": "text/plain" } ], "flagged": false, "summary": "Android: Integrity scout crashes when attempting to create/open window with URL: nativePath", "creator": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "Titanium Studio, build: 1.0.2.201107130739, SDK 1.7.2 97c3689, Android emulator, Nexus One 2.2.2, Nexus S 2.3.4", "comment": { "comments": [ { "id": "423832", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing ticket due to time passed and lack of progress for a number of years. Please open a new ticket if there are any problems.", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-07-10T22:22:50.000+0000", "updated": "2017-07-10T22:22:50.000+0000" } ], "maxResults": 1, "total": 1, "startAt": 0 } } }