{ "id": "172845", "key": "TIMOB-26731", "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": null, "resolutiondate": null, "created": "2019-01-11T12:06:33.000+0000", "priority": null, "labels": [ "android", "engSchedule", "ios" ], "versions": [ { "id": "20275", "name": "Release 7.4.1", "archived": false, "released": true, "releaseDate": "2018-10-18" } ], "issuelinks": [ { "id": "57266", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "149233", "key": "ALOY-1289", "fields": { "summary": "Alloy social.js plug-in incompatible with newest Twitter APIs", "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": "None", "id": "6" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2019-03-26T15:43:27.000+0000", "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" } }, "components": [], "description": "Trying to implement twitter login in my apps, I'm using Alloy.builtins.social.\r\n\r\ntitanium studio SDK 7.4.1GA\r\n\r\nvar social = require('/alloy/social').create({\r\n\t\tconsumerSecret : 'XXXXXXXXXXXXXXXXXXXXXXXXXXXX',\r\n\t\tconsumerKey : 'XXXXXXXXXX'\r\n\t\t});\r\n// btn click event\r\nif (!social.isAuthorized()) {\r\n\tsocial.authorize();\r\n\t}\r\nError parsing a meta element's content: ';' is not a valid key-value pair separator. Please use ',' instead. (8:https://api.twitter.com/oauth/authorize)\r\n\r\n\r\nany help, thanks in advance.", "attachment": [ { "id": "66074", "filename": "Screen Shot 2019-01-12 at 11.40.04 PM.png", "author": { "name": "elienajem22", "key": "elienajem22", "displayName": "NajElie", "active": true, "timeZone": "Asia/Beirut" }, "created": "2019-01-12T21:40:37.000+0000", "size": 38955, "mimeType": "image/png" } ], "flagged": false, "summary": "Trying to implement twitter login in my apps", "creator": { "name": "elienajem22", "key": "elienajem22", "displayName": "NajElie", "active": true, "timeZone": "Asia/Beirut" }, "subtasks": [], "reporter": { "name": "elienajem22", "key": "elienajem22", "displayName": "NajElie", "active": true, "timeZone": "Asia/Beirut" }, "environment": "iPhone & Android", "comment": { "comments": [ { "id": "445223", "author": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "body": "Hello, I can't reproduce the issue on our end with SDK 7.5.0.GA. Tested on iOS 12.1 simulators. I am able to authorize and log in to Twitter. Here is the sample code I used. \r\n{code}\r\nvar social=require('/alloy/social').create({\r\nconsumerSecret:'xxxxxxxxx',consumerKey:'xxxxxxxx'\r\n});\r\nfunction doClick(e) {\r\nif(!social.isAuthorized()) {\r\nsocial.authorize();\r\nconsole.info('authorize');\r\n}\r\n}\r\n$.index.open();\r\n{code}\r\n\r\nTry my code with your key and secret info. Thanks.", "updateAuthor": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "created": "2019-01-11T16:36:50.000+0000", "updated": "2019-01-11T16:36:50.000+0000" }, { "id": "445240", "author": { "name": "elienajem22", "key": "elienajem22", "displayName": "NajElie", "active": true, "timeZone": "Asia/Beirut" }, "body": "Hello sharif, \r\nThanks for your help.\r\n\r\nAre you able to get the user info after social.authorize(function(e){....}); token, email....?\r\n", "updateAuthor": { "name": "elienajem22", "key": "elienajem22", "displayName": "NajElie", "active": true, "timeZone": "Asia/Beirut" }, "created": "2019-01-12T06:27:43.000+0000", "updated": "2019-01-12T06:27:43.000+0000" }, { "id": "445246", "author": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "body": "Hello, Twitter does not allow to get the email address. Can you share the full code that you tried to get the user info? I am trying with \r\n{code}\r\nsocial.authorize(function(e) {\r\n\t\t\talert(JSON.stringify(e));\r\n\t\t});\r\n{code}\r\nI got an app crash with nothing in the log. Can you share your code? thanks.", "updateAuthor": { "name": "sdarda", "key": "sdarda", "displayName": "Sharif AbuDarda", "active": false, "timeZone": "Asia/Dhaka" }, "created": "2019-01-12T21:20:58.000+0000", "updated": "2019-01-12T21:20:58.000+0000" }, { "id": "445247", "author": { "name": "elienajem22", "key": "elienajem22", "displayName": "NajElie", "active": true, "timeZone": "Asia/Beirut" }, "body": " !Screen Shot 2019-01-12 at 11.40.04 PM.png|thumbnail! \r\nTwitter allows to get user's email, kindly check the permissions, my target is to add twitter login on my apps. did u implement it or do u have any ready library.\r\n\r\nmy code is :\r\n\r\nvar social=require('/alloy/social').create({\r\nconsumerSecret:'xxxxxxxxx',\r\nconsumerKey:'xxxxxxxx'\r\n});\r\n\r\nfunction doClick(e) {\r\n\r\nif(!social.isAuthorized()) {\r\n\r\nsocial.authorize();// have callback as per Appcelerator Document, but it doesn't work for me\r\n\r\nconsole.info('authorize');\r\n\r\n}\r\n\r\n}\r\n\r\n$.index.open();\r\n\r\n\r\nThanks in advance ", "updateAuthor": { "name": "elienajem22", "key": "elienajem22", "displayName": "NajElie", "active": true, "timeZone": "Asia/Beirut" }, "created": "2019-01-12T21:43:55.000+0000", "updated": "2019-01-12T21:46:03.000+0000" }, { "id": "445256", "author": { "name": "michael", "key": "michael", "displayName": "Michael Gangolf", "active": true, "timeZone": "Europe/Berlin" }, "body": "I think the Android part is broken. This part https://github.com/appcelerator/alloy/blob/master/Alloy/builtins/social.js#L391 is failing with a timeout for me.\r\nChanging it to\r\n{code}\r\nfunction authorizeUICallback(e) {\r\n var response = e.source.evalJS('(p = document.getElementById(\"oauth_pin\")) && p.innerHTML;');\r\n\t\te.source.evalJS('document.getElementById(\"oauth_pin\").innerHTML', function(response){\r\n\t\t\tif (response && response !=\"\" && response !=\"null\"){\r\n\t\t\t\tresponse = response.replace(/\\\\u003C/g,'<');\r\n\t\t\t\tif (response.split(\"\").length > 0){\r\n\t\t\t\t\tresponse ? (pin = response.split(\"\")[1].split(\"\")[0], destroyAuthorizeUI(), receivePinCallback()) : (loadingView && loadingView.hide(), loadingContainer && loadingContainer.hide(), webView && webView.show()), loading = !1, clearInterval(intervalID), estimates[estimateID] = (new Date).getTime() - startTime, Ti.App.Properties.setString(\"Social-LoadingEstimates\", JSON.stringify(estimates));\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t});\r\n }\r\n{code}\r\n\r\nAlso note that the response contains \\u003C instead of < so the split failed before.", "updateAuthor": { "name": "michael", "key": "michael", "displayName": "Michael Gangolf", "active": true, "timeZone": "Europe/Berlin" }, "created": "2019-01-13T14:45:32.000+0000", "updated": "2019-01-13T14:45:49.000+0000" } ], "maxResults": 5, "total": 5, "startAt": 0 } } }