{ "id": "159091", "key": "TIMOB-23118", "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": [ { "id": "17706", "name": "Release 5.4.0", "archived": false, "released": true, "releaseDate": "2016-08-11" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2016-04-07T23:36:43.000+0000", "created": "2016-03-28T19:24:34.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "dynamicitembehavior", "qe-5.4.0" ], "versions": [], "issuelinks": [], "assignee": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "updated": "2016-08-09T21:29:48.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": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "A community member created a PR to fix a crash that can occur with the above mentioned API. The fix removes the fast-enumeration with a simple {{for}}-iteration.", "attachment": [], "flagged": false, "summary": "iOS: Ti.UI.iOS.DynamicItemBehavior can possibly crash during iteration", "creator": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "subtasks": [], "reporter": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "environment": null, "closedSprints": [ { "id": 618, "state": "closed", "name": "2016 Sprint 08 SDK", "startDate": "2016-04-09T00:30:18.262Z", "endDate": "2016-04-23T00:30:00.000Z", "completeDate": "2016-04-25T02:38:28.511Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "380842", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "PR: https://github.com/appcelerator/titanium_mobile/pull/6600\r\n\r\nDemo:\r\n{code:javascript}\r\nvar win = Ti.UI.createWindow({backgroundColor: 'white', fullscreen: true});\r\n\r\n// Create an Animator object using the window as the coordinate system\r\nvar animator = Ti.UI.iOS.createAnimator({referenceView: win});\r\n\r\n// Create a red block\r\nvar redBlock = Ti.UI.createView({\r\n backgroundColor: 'red',\r\n width: 25,\r\n height: 25,\r\n top: 25,\r\n left: 25\r\n});\r\n\r\n// Change the physics attributes of the red block\r\nvar redDynamic = Ti.UI.iOS.createDynamicItemBehavior({\r\n density: 20.0,\r\n angularResistance: 1.0,\r\n friction: 1.0,\r\n resistance: 1.0,\r\n allowsRotation: false\r\n});\r\nredDynamic.addItem(redBlock);\r\n\r\n// Apply a left push to the red block\r\nvar redPush = Ti.UI.iOS.createPushBehavior({\r\n pushDirection: {x: 2.0, y: 0.0}\r\n});\r\nredPush.addItem(redBlock);\r\n\r\n// Create a blue block\r\nvar blueBlock = Ti.UI.createView({\r\n backgroundColor: 'blue',\r\n width: 50,\r\n height: 50,\r\n top: 25,\r\n right: 25\r\n});\r\n\r\n// Change the physics attributes of the blue block\r\nvar blueDynamic = Ti.UI.iOS.createDynamicItemBehavior({\r\n elasticity: 1.0,\r\n});\r\nblueDynamic.addItem(blueBlock);\r\n\r\n// Apply a right push to the blue block\r\nvar bluePush = Ti.UI.iOS.createPushBehavior({\r\n pushDirection: {x: -2.0, y: 0.0}\r\n});\r\nbluePush.addItem(blueBlock);\r\n\r\n// Create the collision behavior so the items can collide\r\nvar collision = Ti.UI.iOS.createCollisionBehavior();\r\ncollision.addItem(redBlock);\r\ncollision.addItem(blueBlock);\r\n\r\nanimator.addBehavior(redDynamic);\r\nanimator.addBehavior(redPush);\r\nanimator.addBehavior(blueDynamic);\r\nanimator.addBehavior(bluePush);\r\nanimator.addBehavior(collision);\r\n\r\n// Start the animation when the window opens\r\nwin.addEventListener('open', function(e){\r\n animator.startAnimator();\r\n});\r\n\r\nwin.add(redBlock);\r\nwin.add(blueBlock);\r\nwin.open();\r\n{code}", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2016-03-28T19:25:13.000+0000", "updated": "2016-03-28T19:28:54.000+0000" }, { "id": "392765", "author": { "name": "htbryant", "key": "htbryant", "displayName": "Harry Bryant", "active": true, "timeZone": "Europe/London" }, "body": "Verified as fixed, ran the app with the above demo code 10 times without a single crash.\r\n\r\nTested On:\r\niPhone 6S (9.3.3) Device\r\nMac OSX El Capitan 10.11.6\r\nTi SDK: 5.4.0.v20160809033140\r\nAppc Studio: 4.7.0.201607250649\r\nAppc NPM: 4.2.7\t\r\nApp CLI: 5.4.0-40\r\nXcode 7.3.1\r\nNode v4.4.7\r\n*Closing ticket.*", "updateAuthor": { "name": "htbryant", "key": "htbryant", "displayName": "Harry Bryant", "active": true, "timeZone": "Europe/London" }, "created": "2016-08-09T21:29:33.000+0000", "updated": "2016-08-09T21:29:33.000+0000" } ], "maxResults": 2, "total": 2, "startAt": 0 } } }