{ "id": "162371", "key": "TIMOB-23721", "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": "2", "description": "The problem described is an issue which will never be fixed.", "name": "Won't Fix" }, "resolutiondate": "2016-10-03T19:54:03.000+0000", "created": "2016-08-03T19:09:46.000+0000", "priority": { "name": "Low", "id": "4" }, "labels": [ "qe-5.4.0" ], "versions": [ { "id": "17706", "name": "Release 5.4.0", "archived": false, "released": true, "releaseDate": "2016-08-11" } ], "issuelinks": [], "assignee": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "updated": "2017-08-16T01:06:37.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": "The following error is thrown when calling the createTabGroup method without specifying any tabs:\r\n{code:java}\r\n[WARN] : Attempted to load TiUITabGroupProxy: Could not find class definition.\r\n[ERROR] : Script Error {\r\n[ERROR] : column = 49;\r\n[ERROR] : line = 1;\r\n[ERROR] : message = \"invalid method (createTabGroup) passed to UIModule\";\r\n[ERROR] : sourceURL = \"file:///var/containers/Bundle/Application/4971331A-066C-4C17-BA2D-3DC44E634884/ShamWise.app/app.js\";\r\n[ERROR] : stack = \"[native code]\\nfile:///var/containers/Bundle/Application/4971331A-066C-4C17-BA2D-3DC44E634884/ShamWise.app/app.js:1:49\";\r\n[ERROR] : }\r\n{code}\r\n\r\nThe issue is resolved when specifying at least one tab as follows:\r\n{code:java}\r\n\t var tabGroup = Ti.UI.createTabGroup();\r\n\t \r\n\t var tab1 = Ti.UI.createTab({\r\n\t \ttitle: \"Tab1\"\r\n\t });\r\n\t \r\n\t tabGroup.add(tab1); \r\n\t tabGroup.open();\r\n{code}\r\n\r\n*This occurs only on the iOS platform, the demo code launches without issue on the Android platform.*\r\n\r\nh3. TEST CODE:\r\n{code:java}\r\n\t var tabGroup = Ti.UI.createTabGroup();\r\n\t tabGroup.open();\r\n{code}\r\n\r\nh2. Steps to Reproduce\r\n1. Create a classic mobile project\r\n2. Include the test code above in the app.js\r\n3. Build to sim / device\r\n4. Launch the app\r\n\r\nh2. Actual Result\r\n\r\nError is thrown upon launch.\r\n\r\nh2. Expected Result\r\n\r\nApp should launch an empty tabGroup view without issue.\r\n\r\n", "attachment": [], "flagged": false, "summary": "iOS: Invalid method (createTabGroup) passed to UIModule", "creator": { "name": "htbryant", "key": "htbryant", "displayName": "Harry Bryant", "active": true, "timeZone": "Europe/London" }, "subtasks": [], "reporter": { "name": "htbryant", "key": "htbryant", "displayName": "Harry Bryant", "active": true, "timeZone": "Europe/London" }, "environment": "iPhone 6S (9.3.3) Device & iPhone 6 Plus (8.3) Device\r\nMac OSX El Capitan 10.11.6\r\nTi SDK: 5.4.0.v20160802165655\r\nAppc Studio: 4.7.0.201607111053\r\nAppc NPM: 4.2.7\t\r\nApp CLI: 5.4.0-37\r\nXcode 7.3\r\nNode v4.4.7", "comment": { "comments": [ { "id": "392344", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "Wait a second, you are trying to add a tab to the tabgroup that does not hold a window in it. Without it, the tabgroup has no context and could break. Check if that could be the reason.\r\n\r\n*EDIT*: In addition, it is {{addTab}} and not {{add}}.\r\n*EDIT2*: Ok, here is the thing why it doesn't work for you but me / iOS devs:\r\nThe above code does not have a tab in it. After some research I found out that our implementation is the following (simplified):\r\n{code:objc}\r\n#ifdef USE_TI_UITAB\r\n...\r\n@implementation TiUITabGroup\r\n...\r\n@end\r\n#endif\r\n{code}\r\nWhat that does is, that it only compiles the {{TiUITabGroup}} class if a {{TiUITab}} is defined. Since all compiler-macros are pre-defined in the Xcode source-project, [~cng] and me didn't see the error before. For the compiled SDK, those macros are generically generated as soon as you do {{Ti.UI.createTab()}} at least once, we also call it \"symbols\". \r\n\r\nSo long story short: That is how it is done since forever, since we don't want users to create empty tabgroups. If we want now, we can make it an improvement-ticket, otherwise, that's it.", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2016-08-03T20:02:10.000+0000", "updated": "2016-08-03T20:17:49.000+0000" }, { "id": "397933", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "[~htbryant] Resolving for now, since I didn't hear anything back since a while. If you think we need an improvement ticket, I'd be fine with that!", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2016-10-03T19:54:03.000+0000", "updated": "2016-10-03T19:54:03.000+0000" }, { "id": "426745", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing with reference to the above comments.", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-08-16T01:06:37.000+0000", "updated": "2017-08-16T01:06:37.000+0000" } ], "maxResults": 3, "total": 3, "startAt": 0 } } }