{"action":"created","issue":{"url":"https://api.github.com/repos/xamarin/Xamarin.Auth/issues/151","repository_url":"https://api.github.com/repos/xamarin/Xamarin.Auth","labels_url":"https://api.github.com/repos/xamarin/Xamarin.Auth/issues/151/labels{/name}","comments_url":"https://api.github.com/repos/xamarin/Xamarin.Auth/issues/151/comments","events_url":"https://api.github.com/repos/xamarin/Xamarin.Auth/issues/151/events","html_url":"https://github.com/xamarin/Xamarin.Auth/issues/151","id":212201230,"number":151,"title":"Completed event not fired on IOS","user":{"login":"BenDevelopment","id":6674194,"avatar_url":"https://avatars3.githubusercontent.com/u/6674194?v=3","gravatar_id":"","url":"https://api.github.com/users/BenDevelopment","html_url":"https://github.com/BenDevelopment","followers_url":"https://api.github.com/users/BenDevelopment/followers","following_url":"https://api.github.com/users/BenDevelopment/following{/other_user}","gists_url":"https://api.github.com/users/BenDevelopment/gists{/gist_id}","starred_url":"https://api.github.com/users/BenDevelopment/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BenDevelopment/subscriptions","organizations_url":"https://api.github.com/users/BenDevelopment/orgs","repos_url":"https://api.github.com/users/BenDevelopment/repos","events_url":"https://api.github.com/users/BenDevelopment/events{/privacy}","received_events_url":"https://api.github.com/users/BenDevelopment/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":11,"created_at":"2017-03-06T17:58:14Z","updated_at":"2017-03-09T13:07:16Z","closed_at":null,"body":"The Completed event is not fired on IOS, Safari keep navigate to the callback url without telling what happened.\r\nThe token cannot be catched.\r\n```\r\npublic override void ViewDidAppear(bool animated)\r\n{\r\n    base.ViewDidAppear(animated);\r\n\r\n    if (_isShown) return;\r\n    _isShown = true;\r\n\r\n    var auth = AuthenticationHelper.CreateOAuth2Authenticator(Provider);\r\n    auth.Completed += OnAuthenticationCompleted;\r\n    var view = auth.GetUI() as UINavigationController;\r\n    PresentViewController(view, true, null);\r\n}\r\n\r\nasync void OnAuthenticationCompleted(object sender, AuthenticatorCompletedEventArgs e)\r\n{\r\n    // NOT FIRED HERE\r\n    if (e.IsAuthenticated)\r\n    {\r\n        var access_token = e.Account.Properties.FirstOrDefault(i => i.Key.Equals(\"access_token\")).Value ?? string.Empty;\r\n        await AuthenticationHelper.SocialCallback(Provider, access_token);\r\n    }\r\n    else\r\n        await Navigator.Instance.CloseAuthentication();\r\n}\r\n```"},"comment":{"url":"https://api.github.com/repos/xamarin/Xamarin.Auth/issues/comments/285346351","html_url":"https://github.com/xamarin/Xamarin.Auth/issues/151#issuecomment-285346351","issue_url":"https://api.github.com/repos/xamarin/Xamarin.Auth/issues/151","id":285346351,"user":{"login":"moljac","id":1768576,"avatar_url":"https://avatars1.githubusercontent.com/u/1768576?v=3","gravatar_id":"","url":"https://api.github.com/users/moljac","html_url":"https://github.com/moljac","followers_url":"https://api.github.com/users/moljac/followers","following_url":"https://api.github.com/users/moljac/following{/other_user}","gists_url":"https://api.github.com/users/moljac/gists{/gist_id}","starred_url":"https://api.github.com/users/moljac/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/moljac/subscriptions","organizations_url":"https://api.github.com/users/moljac/orgs","repos_url":"https://api.github.com/users/moljac/repos","events_url":"https://api.github.com/users/moljac/events{/privacy}","received_events_url":"https://api.github.com/users/moljac/received_events","type":"User","site_admin":false},"created_at":"2017-03-09T13:07:16Z","updated_at":"2017-03-09T13:07:16Z","body":"@BenDevelopment @DFerenczi @mkroghj \r\n\r\nSo, my tests iOS != 10.x, nuget 1.3.2.5\r\n\r\n(abandoned search for 10.x issues until new features are implemented)\r\n\r\n* FaceBook WWW type app Redirect URL http[s]://xamarin.com        \r\n   OK\r\n* FaceBook WWW type app Redirect URL http[s]://localhost        \r\n   OK (getting access_token with error trying to load localhost!)\r\n* FaceBook WWW type app Redirect URL http[s]://127.0.0.1        \r\n   OK (getting access_token with error trying to load localhost!)\r\n* github app Redirect URL http://xamarin.com        \r\n   OK\r\n* github app Redirect URL https://xamarin.com        \r\n   OK\r\n* github app Redirect URL https://localhost        \r\n   OK\r\n* github app Redirect URL https://127.0.0.1        \r\n   OK\r\n\r\nNOTE: \r\n\r\n* support for hosts like localhost and 127.0.0.1 is NEW\r\n* NOT using custom url scheme[s]! This was never supported in Xamarin.Auth and this is under heavy development right now. Thus SFSafariViewController will NOT work (it might if you are lucky, but I would not bet).\r\n\r\n"}}
{"actor":{"display_login":"moljac"}}