{ "id": "120488", "key": "TIMOB-15357", "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": "15707", "description": "2013 Sprint 23", "name": "2013 Sprint 23", "archived": true, "released": true, "releaseDate": "2013-11-15" }, { "id": "15708", "description": "2013 Sprint 23 API", "name": "2013 Sprint 23 API", "archived": true, "released": true, "releaseDate": "2013-11-15" }, { "id": "14982", "description": "Release 3.2.0", "name": "Release 3.2.0", "archived": false, "released": true, "releaseDate": "2013-12-19" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2013-11-12T22:35:59.000+0000", "created": "2013-09-26T18:33:50.000+0000", "priority": { "name": "Critical", "id": "1" }, "labels": [ "qe-closed-3.2.0", "triage" ], "versions": [], "issuelinks": [ { "id": "32432", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "120719", "key": "MOD-1568", "fields": { "summary": "iOS: Module API should contain full iOS lifecycle event support", "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": "Low", "id": "4" }, "issuetype": { "id": "2", "description": "A new feature of the product, which has yet to be developed.", "name": "New Feature", "subtask": false } } } } ], "assignee": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "updated": "2013-12-13T01:07:19.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 app delegate in iPhone/Classes/TiApp.m uses the above deprecated method:\r\n\r\n[handleOpenURL|https://developer.apple.com/library/ios/documentation/uikit/reference/UIApplicationDelegate_Protocol/Reference/Reference.html#//apple_ref/occ/intfm/UIApplicationDelegate/application:handleOpenURL:]\r\n\r\nThe problem with this is that this method doesn't receive the sourceApplication identifier from the calling app. To use the new Facebook SDKs the app must use the newer openURL method, which can enable the Facebook module to know who is the calling app (e.g. - the native Facebook application which is calling our app for deep linking, share dialog, etc.). I assume there may be other apps besides Facebook which may be causing similar issues, thus this is critical.\r\n\r\nPlease implement this for 3.2.0 as well as a backport for 3.1.x", "attachment": [], "flagged": false, "summary": "iOS: App delegate uses deprecated method handleOpenURL, which disables new Facebook SDK", "creator": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "subtasks": [], "reporter": { "name": "mrahman", "key": "mrahman", "displayName": "Mostafizur Rahman", "active": true, "timeZone": "Asia/Dhaka" }, "environment": "SDK 3.1.3.GA", "comment": { "comments": [ { "id": "273016", "author": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "body": "Pull request: https://github.com/appcelerator/titanium_mobile/pull/4739\nFor a concise example of the necessity of this, see https://developers.facebook.com/docs/ios/app-links/\nYou can see that Facebook app link functionality needs to know the sourceApplication, and this is available only in openURL and not handleOpenURL, as in their example.", "updateAuthor": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "created": "2013-09-26T18:49:09.000+0000", "updated": "2013-09-26T18:49:09.000+0000" }, { "id": "273131", "author": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "body": "This should not be low priority: in the current SDK, when an app is opened by URL (e.g. return from Facebook dialog, deep linking, etc) the app has *NO CLUE* which app called it. If you want to use new Facebook SDKs - you *MUST* fix this. Since I submitted the PR, and since it's only about 5 lines of code that can be easily tested, please rethink the priority on this.", "updateAuthor": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "created": "2013-09-27T06:39:49.000+0000", "updated": "2013-09-27T06:39:49.000+0000" }, { "id": "273181", "author": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "body": "[~mokesmokes] I'm not sure why this was marked as low priority. I've changed it.", "updateAuthor": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-09-27T16:28:27.000+0000", "updated": "2013-09-27T16:28:27.000+0000" }, { "id": "273242", "author": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "body": "A related note: the Titanium iOS module API only supports app events such as applicationWillResignActive, applicationDidBecomeActive, etc. There is no direct support for openURL (or its predecessor handleOpenURL) - rather the code in TiApp.m saves the URL info in the launchOptions object, and the module is supposed to \"infer\" this data during applicationDidBecomeActive/resumed event. This is really weird logic, for several reasons:\r\n1) On occasion \"resumed\" can occur right after \"suspend\", without any other events in between - e.g. when the user rejects a phone call.\r\n2) The current iOS specs are a bit ambiguous as to the order of these events, and if they decide to call openURL after the resumed event - this logic will break. With the current wording in the Apple docs, this is quite possible.\r\n\r\nAll I did in my pull request was update to openURL and save the relevant info - this PR seems \"safe\" in my eyes. However, the additional fix, in my opinion, is for the module API to also support a \"urlReceived\" event, to directly support URL calls, and not \"infer\" them in ambiguous fashion from \"resumed\" events.\r\nThe iOS reference on this: https://developer.apple.com/library/ios/DOCUMENTATION/UIKit/Reference/UIApplicationDelegate_Protocol/Reference/Reference.html", "updateAuthor": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "created": "2013-09-27T20:16:03.000+0000", "updated": "2013-09-27T20:16:03.000+0000" }, { "id": "273520", "author": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "body": "I would like to note that I'm using this PR in production code on my branch of 3.1.3, and it works with the Facebook app calls in the new SDK (for which I will also submit a PR soon). I have not seen any negative side effects to this code.", "updateAuthor": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "created": "2013-10-01T18:54:44.000+0000", "updated": "2013-10-01T18:54:44.000+0000" }, { "id": "273581", "author": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "updateAuthor": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "created": "2013-10-02T05:19:05.000+0000", "updated": "2013-10-02T05:19:05.000+0000" }, { "id": "279232", "author": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "body": "PR https://github.com/appcelerator/titanium_mobile/pull/4739 merged", "updateAuthor": { "name": "vduggal", "key": "vduggal", "displayName": "Vishal Duggal", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2013-11-12T22:35:59.000+0000", "updated": "2013-11-12T22:35:59.000+0000" }, { "id": "284139", "author": { "name": "wluu", "key": "wluu", "displayName": "Wilson Luu", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing ticket as fixed. Verified using KS test (Base UI > Views > Web Views > External URL) and logging into Facebaook (Mashups > Facebook > Login/Logout).\r\n\r\nTested on:\r\n\r\nAppcelerator Studio, build: 3.2.0.201312101708\r\nSDK build: 3.2.0.v20131212122847\r\nCLI: 3.2.0-cr3\r\nAlloy: 1.3.0-cr\r\nXcode: 5.0.2\r\nDevice: iphone 5s (7.0), iphone 5 (6.1.3)", "updateAuthor": { "name": "wluu", "key": "wluu", "displayName": "Wilson Luu", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2013-12-12T23:52:38.000+0000", "updated": "2013-12-13T01:05:35.000+0000" } ], "maxResults": 9, "total": 9, "startAt": 0 } } }