{ "id": "102564", "key": "TIMOB-11986", "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": "14162", "description": "Release 3.1.0", "name": "Release 3.1.0", "archived": true, "released": true, "releaseDate": "2013-04-16" }, { "id": "14811", "description": "2013 Sprint 01 API", "name": "2013 Sprint 01 API", "archived": true, "released": true, "releaseDate": "2013-01-14" }, { "id": "14804", "description": "2013 Sprint 01", "name": "2013 Sprint 01", "archived": true, "released": true, "releaseDate": "2013-01-14" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2013-01-08T15:19:58.000+0000", "created": "2012-10-03T04:18:14.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "api", "crash", "ios", "ios6", "triage" ], "versions": [], "issuelinks": [ { "id": "24267", "type": { "id": "10000", "name": "Blocks", "inward": "is blocked by", "outward": "blocks" }, "inwardIssue": { "id": "107573", "key": "TIMOB-12244", "fields": { "summary": "iOS; TabGroup.setActiveTab() calls ignored on a previously opened tabgroup", "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": "Critical", "id": "1" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } }, { "id": "34243", "type": { "id": "10002", "name": "Duplicate", "inward": "is duplicated by", "outward": "duplicates" }, "inwardIssue": { "id": "109174", "key": "AC-2321", "fields": { "summary": "iOS: App crashes with: \"A view can only be associated with at most one view controller at a time\"", "status": { "description": "A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.", "name": "Resolved", "id": "5", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } }, { "id": "24264", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "103934", "key": "TIMOB-11578", "fields": { "summary": "iOS: Unable to set ActiveTab on tabGroup", "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": "Critical", "id": "1" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } }, { "id": "24265", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "107573", "key": "TIMOB-12244", "fields": { "summary": "iOS; TabGroup.setActiveTab() calls ignored on a previously opened tabgroup", "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": "Critical", "id": "1" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } }, { "id": "24266", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "101000", "key": "TIMOB-10891", "fields": { "summary": "iOS: App having 'tabgroup containing map' crashes when opened from a window (iOS 6)", "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": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "updated": "2014-01-11T05:20:24.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": "Same build is tested on a device with ios5 and multiple devices with ios6. The problem is consistent on ios6 devices, while ios5 devices work fine.\r\n\r\nUnfortunately I can't paste a self contained example of the working code, but here's what's going on.\r\n\r\nFrom one tab, another tab is set active with a window opened (some of the views and the window are earlier declared and previously used).\r\n\r\nthis is the code, but it's pretty generic if out of context...\r\n\r\nself.open = function() {\r\n trip_tab.open(win, {animated: false});\r\n tabGroup.setActiveTab(trip_tab).open();\r\n};\r\n\r\n...\r\n...\r\n...\r\n\r\nself.open();\r\n\r\n\r\nHere's the console log:\r\n\r\n\r\n[ERROR] The application has crashed with an unhandled exception. Stack trace:\r\n0 CoreFoundation 0x03230012 __exceptionPreprocess + 178\r\n1 libobjc.A.dylib 0x02f93e7e objc_exception_throw + 44\r\n2 CoreFoundation 0x0322fdeb +[NSException raise:format:] + 139\r\n3 UIKit 0x00df2309 -[UIView(Internal) _setViewDelegate:] + 226\r\n4 UIKit 0x00e895ac +[UIViewController setViewController:forView:] + 40\r\n5 UIKit 0x00e85a90 -[UIViewController setView:] + 521\r\n6 Citybot 0x00080aec -[TiViewController loadView] + 92\r\n7 Citybot 0x000c6863 -[TiUITabController loadView] + 179\r\n8 UIKit 0x00e85648 -[UIViewController loadViewIfRequired] + 73\r\n9 UIKit 0x00e85882 -[UIViewController view] + 33\r\n10 UIKit 0x00e85b2a -[UIViewController contentScrollView] + 36\r\n11 UIKit 0x00e9cef5 -[UINavigationController _computeAndApplyScrollContentInsetDeltaForViewController:] + 36\r\n12 UIKit 0x00e9cfdb -[UINavigationController _layoutViewController:] + 43\r\n13 UIKit 0x00e9d286 -[UINavigationController _updateScrollViewFromViewController:toViewController:] + 254\r\n14 UIKit 0x00e9d381 -[UINavigationController _startTransition:fromViewController:toViewController:] + 72\r\n15 UIKit 0x00e9deab -[UINavigationController _startDeferredTransitionIfNeeded:] + 386\r\n16 UIKit 0x00e9dfc9 -[UINavigationController _startDeferredTransitionIfNeeded] + 41\r\n17 UIKit 0x00e9e055 -[UINavigationController __viewWillLayoutSubviews] + 33\r\n18 UIKit 0x00fa33ab -[UILayoutContainerView layoutSubviews] + 233\r\n19 UIKit 0x00df492d -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 279\r\n20 libobjc.A.dylib 0x02fa76b0 -[NSObject performSelector:withObject:] + 70\r\n21 QuartzCore 0x02145fc0 -[CALayer layoutSublayers] + 240\r\n22 QuartzCore 0x0213a33c _ZN2CA5Layer16layout_if_neededEPNS_11TransactionE + 468\r\n23 QuartzCore 0x0213a150 _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 26\r\n24 QuartzCore 0x020b80bc _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 324\r\n25 QuartzCore 0x020b9227 _ZN2CA11Transaction6commitEv + 395\r\n26 QuartzCore 0x0215bb50 +[CATransaction flush] + 52\r\n27 UIKit 0x00dba52f _afterCACommitHandler + 132\r\n28 CoreFoundation 0x031f8afe __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 30\r\n29 CoreFoundation 0x031f8a3d __CFRunLoopDoObservers + 381\r\n30 CoreFoundation 0x031d67c2 __CFRunLoopRun + 1106\r\n31 CoreFoundation 0x031d5f44 CFRunLoopRunSpecific + 276\r\n32 CoreFoundation 0x031d5e1b CFRunLoopRunInMode + 123\r\n33 GraphicsServices 0x0381c7e3 GSEventRunModal + 88\r\n34 GraphicsServices 0x0381c668 GSEventRun + 104\r\n35 UIKit 0x00da465c UIApplicationMain + 1211\r\n36 Citybot 0x000068a8 main + 456\r\n37 Citybot 0x000031d5 start + 53\r\n2012-10-02 17:36:09.101 Citybot[63976:c07] *** Terminating app due to uncaught exception 'UIViewControllerHierarchyInconsistency', reason: 'A view can only be associated with at most one view controller at a time! View > is associated with . Clear this association before associating this view with .'\r\n*** First throw call stack:\r\n(0x3230012 0x2f93e7e 0x322fdeb 0xdf2309 0xe895ac 0xe85a90 0x80aec 0xc6863 0xe85648 0xe85882 0xe85b2a 0xe9cef5 0xe9cfdb 0xe9d286 0xe9d381 0xe9deab 0xe9dfc9 0xe9e055 0xfa33ab 0xdf492d 0x2fa76b0 0x2145fc0 0x213a33c 0x213a150 0x20b80bc 0x20b9227 0x215bb50 0xdba52f 0x31f8afe 0x31f8a3d 0x31d67c2 0x31d5f44 0x31d5e1b 0x381c7e3 0x381c668 0xda465c 0x68a8 0x31d5)\r\n[INFO] Application has exited from Simulator\r\n\r\n\r\nI just installed 2.1.3 rc2 from here http://builds.appcelerator.com.s3.amazonaws.com/mobile/2_1_X/mobilesdk-2.1.3.v20120927181611-osx.zip\r\n\r\nI was hoping the problem was this (there is in fact map used in that view/window):\r\nTIMOB-10891 iOS 6: Repeatedly opening a tab group containing a map view crashes the application. (Known issue in RC)\r\n(described here: http://developer.appcelerator.com/blog/2012/09/titanum-2-1-3-rc2-is-released-with-additional-fixes-for-ios-6-and-iphone-5.html )\r\n\r\nBut after updating from previous rc to rc2 the problem still exits...\r\n\r\nPlease contact me -- I'll be happy to assist with troubleshooting this.\r\n\r\nThank you.", "attachment": [ { "id": "34624", "filename": "app.js", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2013-01-08T15:03:39.000+0000", "size": 1481, "mimeType": "text/javascript" } ], "flagged": false, "summary": "iOS: App crashes with: \"A view can only be associated with at most one view controller at a time\"", "creator": { "name": "zhenya", "key": "zhenya", "displayName": "Zhenya Kogan", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "zhenya", "key": "zhenya", "displayName": "Zhenya Kogan", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "ios6 (simulator and device)", "comment": { "comments": [ { "id": "221921", "author": { "name": "zhenya", "key": "zhenya", "displayName": "Zhenya Kogan", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Fyi, as a temporary workaround I switched the calls from\ntrip_tab.open(win, {animated: false});\ntabGroup.setActiveTab(trip_tab).open();\n\nto\ntabGroup.setActiveTab(trip_tab).open();\ntrip_tab.open(win, {animated: false});\n\nThis solved the problem, however this is not optimal as a long term fix since there's a short flicker of a previous window in that tab now.", "updateAuthor": { "name": "zhenya", "key": "zhenya", "displayName": "Zhenya Kogan", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-10-03T18:26:07.000+0000", "updated": "2012-10-03T18:26:07.000+0000" }, { "id": "222161", "author": { "name": "zhenya", "key": "zhenya", "displayName": "Zhenya Kogan", "active": true, "timeZone": "America/Los_Angeles" }, "body": "The fix I described above no longer works after 2.1.3 GA update.", "updateAuthor": { "name": "zhenya", "key": "zhenya", "displayName": "Zhenya Kogan", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-10-04T21:50:21.000+0000", "updated": "2012-10-04T21:50:21.000+0000" }, { "id": "225263", "author": { "name": "zhenya", "key": "zhenya", "displayName": "Zhenya Kogan", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Any news on this?", "updateAuthor": { "name": "zhenya", "key": "zhenya", "displayName": "Zhenya Kogan", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-10-28T21:50:55.000+0000", "updated": "2012-10-28T21:50:55.000+0000" }, { "id": "230158", "author": { "name": "dsefton", "key": "dsefton", "displayName": "Daniel Sefton", "active": true, "timeZone": "America/Los_Angeles" }, "body": "We'd be able to look at this faster with a test case, are you sure it's not possible to put one together? I don't expect you to paste your production code, but just try to re-create the problem in a new simple project. Thanks!", "updateAuthor": { "name": "dsefton", "key": "dsefton", "displayName": "Daniel Sefton", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-12-06T00:18:18.000+0000", "updated": "2012-12-06T00:18:18.000+0000" }, { "id": "233601", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Sample test project which recreates the problem", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2013-01-08T14:55:44.000+0000", "updated": "2013-01-08T14:55:44.000+0000" }, { "id": "233604", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "The Tabgroup implemetation on 2_1_X had a bug with state retention which was fixed as part of TIMOB-10891\r\nRun the attached sample app against 2_1_X and you'll see that opening the tabgroup a second time will close win2.\r\nRun this against master or 3_0_X CI and it should work fine (TIMOB-12244 was a bug discovered during the triage of this bug and has been fixed.)\r\n\r\nThe crash happens because a window is being associated with two navControllers at the same time.\r\n\r\nSince 3_0_X and master now have proper state retention, you shouldn't have to call trip_tab.open(win, {animated: false}); if the window is already open. You could write the app along the guidelines presented in the attached app.js\r\n\r\nTo workaround the bug in 2_1_X I recommend explicitly closing the window before closing the tabGroup.", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2013-01-08T15:15:52.000+0000", "updated": "2013-01-08T15:16:18.000+0000" }, { "id": "233605", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Nothing to do here. State retention has been fixed in 3_0_X and master. App can be fixed with JS workaround", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2013-01-08T15:19:58.000+0000", "updated": "2013-01-08T15:19:58.000+0000" }, { "id": "234888", "author": { "name": "ssekhri", "key": "ssekhri", "displayName": "Satyam Sekhri", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Tested with the attached app.js and instructions in the comment.\r\nVerified on:\r\nStudio: 3.0.1.201212181159\r\nSDK: 3.0.0.GA, 3.0.1.v20130108154840, 3.1.0.v20130114171802\r\niOS Device: iOS Simulator 6.0, iPad mini (v6.0)\r\nXCode: 4.5.2\r\nCLI: 3.0.22", "updateAuthor": { "name": "ssekhri", "key": "ssekhri", "displayName": "Satyam Sekhri", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-01-18T02:18:55.000+0000", "updated": "2013-01-18T02:18:55.000+0000" }, { "id": "237209", "author": { "name": "a.marcone", "key": "a.marcone", "displayName": "Alberto Marcone", "active": true, "timeZone": "Europe/Berlin" }, "body": "still happening here, just tested it on TiSDK 3.1.0.v20130201161008, iPad 4 Gen, iOS 6.\r\nIt doesn't always happen, but from time to time my app would freeze with this error.\r\n\r\nI'm planning on preparing a dummy project, don't really have time now. Just to let you guys know.", "updateAuthor": { "name": "a.marcone", "key": "a.marcone", "displayName": "Alberto Marcone", "active": true, "timeZone": "Europe/Berlin" }, "created": "2013-02-05T10:13:22.000+0000", "updated": "2013-02-05T10:13:22.000+0000" }, { "id": "237210", "author": { "name": "a.marcone", "key": "a.marcone", "displayName": "Alberto Marcone", "active": true, "timeZone": "Europe/Berlin" }, "body": "still happening here, just tested it on TiSDK 3.1.0.v20130201161008, iPad 4 Gen, iOS 6.\r\nIt doesn't always happen, but from time to time my app would freeze with this error.\r\n\r\nI'm planning on preparing a dummy project, don't really have time now. Just to let you guys know.", "updateAuthor": { "name": "a.marcone", "key": "a.marcone", "displayName": "Alberto Marcone", "active": true, "timeZone": "Europe/Berlin" }, "created": "2013-02-05T10:13:51.000+0000", "updated": "2013-02-05T10:13:51.000+0000" } ], "maxResults": 11, "total": 11, "startAt": 0 } } }