{ "id": "116111", "key": "AC-2190", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "12217", "key": "AC", "name": "Appcelerator - INBOX", "projectCategory": { "id": "10000", "description": "", "name": "Customer Service" } }, "resolution": { "id": "5", "description": "All attempts at reproducing this issue failed, or not enough information was available to reproduce the issue. Reading the code produces no clues as to why this behavior would occur. If more information appears later, please reopen the issue.", "name": "Cannot Reproduce" }, "resolutiondate": "2013-09-09T20:50:22.000+0000", "created": "2013-06-18T11:41:02.000+0000", "labels": [ "facebook", "module" ], "versions": [], "issuelinks": [ { "id": "29657", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "113117", "key": "TIMOB-14205", "fields": { "summary": "iOS: Facebook Login Callback Not Working", "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" } }, "priority": { "name": "Medium", "id": "3" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "updated": "2016-03-08T07:41:10.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": "14550", "name": "Appcelerator Modules", "description": "Please enter tickets related to Modules here." }, { "id": "14548", "name": "Titanium SDK & CLI", "description": "Please enter tickets related to the MobileSDK here." } ], "description": "*Steps to reproduce*\r\n1. Build for Android device \r\n2. Click login button, wait for login event\r\n3. Click logout button\r\n4. Click back button to close app\r\n5. Repeat above steps a few times. After a few iterations (usually just 2 or 3), clicking the login button seems to have no effect.\r\n6. At this point, check the Android logs. I see the following message: com.facebook.Session Should not pass a read permission (email) to a request for publish or manage authorization . Something is clearly wrong, as my app never asked for anything besides email permission.\r\n7. At this point, only closing the app enables recovery. This causes a major usability problem on Android.\r\n\r\n*index.js*\r\n{code:javascript}\r\nvar loggedIn = undefined;\r\nvar fb = require('facebook');\r\nfb.appid = 'YOUR_APP_ID';\r\nfb.permissions = ['email'];\r\nfb.forceDialogAuth = false;\r\n\r\nfunction doLogin(e) {\r\n\tfb.authorize();\r\n}\r\n\r\nfunction doLogout(e){\r\n\tfb.logout();\r\n} \r\n\r\nfunction loggedInState() {\r\n\t$.initLabel.visible = false;\r\n\t$.logoutBtn.visible = true;\r\n\t$.loginBtn.visible = false;\t\r\n\tTi.API.info('Access token in case we need to debug: ' + fb.accessToken);\t\r\n}\r\n\r\nfunction loggedOutState() {\r\n\t$.initLabel.visible = false;\r\n\t$.logoutBtn.visible = false;\r\n\t$.loginBtn.visible = true;\t\r\n}\r\n\r\nfb.addEventListener('logout', function() {\r\n\tloggedOutState();\r\n});\r\n\r\nfb.addEventListener('login', function(e) {\r\n\tTi.API.info('Facebook login event, data:' + JSON.stringify(e.data) + ' cancelled: ' + e.cancelled + \r\n\t\t' error: ' + e.error + ' type: ' + e.type + ' uid: ' + e.uid + ' success: ' + e.success);\r\n\tif (e.success) {\r\n\t\tloggedInState();\r\n\t\talert('Login success, see console logs for user data');\r\n\t} else if (e.error) {\r\n\t\talert ('Login error: ' + e.error);\r\n\t\tloggedOutState();\r\n\t} else if (e.cancelled) { // do nothing\r\n\t\talert('Login cancelled');\r\n\t\tloggedOutState();\r\n\t} else {\r\n\t\talert('no success, no error, and not cancelled... assume loggedOutState');\r\n\t\tloggedOutState();\r\n\t}\r\n});\r\n\r\nloggedIn = fb.getLoggedIn();\r\nTi.API.info('logged in: ' + loggedIn); \r\nif (loggedIn) {\r\n\tloggedInState();\r\n}\r\n\r\nif (loggedIn === false) {\r\n\tloggedOutState();\r\n}\r\n\r\n$.index.open();\r\n{code} \r\n\r\n*index.xml*\r\n{code:xml} \r\n\r\n\t\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\r\n\r\n{code} \r\n\r\n*index.tss*\r\n{code:css}\r\n\".container\": {\r\n\tbackgroundColor:\"white\"\r\n},\r\n\"#initLabel\": {\r\n\twidth: Ti.UI.SIZE,\r\n\theight: Ti.UI.SIZE,\r\n\tcolor: \"#000\",\r\n\tvisible: true\r\n} ,\r\n\"#loginBtn\": {\r\n\tvisible: false\r\n},\r\n\"#logoutBtn\": {\r\nvisible: false\r\n}\r\n{code}\r\n\r\n*tiapp.xml extract*\r\n{code:xml}\r\ncom.test.ti \r\nYOUR_APP_ID\r\n...\r\n \r\n \t\r\n \tfacebook\r\n \tfacebook\r\n \r\n{code}", "attachment": [], "flagged": false, "summary": "Android: Facebook login occasionally hangs", "creator": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "subtasks": [], "reporter": { "name": "mokesmokes", "key": "mokesmokes", "displayName": "Mark Mokryn", "active": true, "timeZone": "Asia/Jerusalem" }, "environment": "Android Facebook module 3.0.0 (the version shipped with 3.1.1 SDK), Ti SDK 3.1.0.GA\r\nGoogle Nexus S, Android 4.1.2, Facebook app version 3.3", "comment": { "comments": [ { "id": "270411", "author": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "body": "Tested this, looks working just fine. ", "updateAuthor": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "created": "2013-09-09T20:50:22.000+0000", "updated": "2013-09-09T20:50:22.000+0000" }, { "id": "286964", "author": { "name": "janhelleman", "key": "janhelleman", "displayName": "Jan Helleman", "active": true, "timeZone": "Europe/Berlin" }, "body": "I have the same issue on 3.2.0 with fb module 3.0.2. When clicking the button the log says \"W/com.facebook.Session: Should not pass a read permission (email) to a request for publish or manage authorization\" and no auth popup appears. The code:\n\nAlloy.Globals.Facebook = require('facebook');\nAlloy.Globals.Facebook.appid = 'xxx';\nAlloy.Globals.Facebook.permissions = ['email'];\nAlloy.Globals.Facebook.forceDialogAuth = false;", "updateAuthor": { "name": "janhelleman", "key": "janhelleman", "displayName": "Jan Helleman", "active": true, "timeZone": "Europe/Berlin" }, "created": "2014-01-07T16:13:02.000+0000", "updated": "2014-01-07T16:13:02.000+0000" } ], "maxResults": 5, "total": 5, "startAt": 0 } } }