{"action":"created","issue":{"url":"https://api.github.com/repos/pusher/pusher-websocket-swift/issues/176","repository_url":"https://api.github.com/repos/pusher/pusher-websocket-swift","labels_url":"https://api.github.com/repos/pusher/pusher-websocket-swift/issues/176/labels{/name}","comments_url":"https://api.github.com/repos/pusher/pusher-websocket-swift/issues/176/comments","events_url":"https://api.github.com/repos/pusher/pusher-websocket-swift/issues/176/events","html_url":"https://github.com/pusher/pusher-websocket-swift/issues/176","id":305868572,"number":176,"title":"Deliberate disconnection - skipping reconnect attempts","user":{"login":"Vincent-CDeng","id":7417471,"avatar_url":"https://avatars3.githubusercontent.com/u/7417471?v=4","gravatar_id":"","url":"https://api.github.com/users/Vincent-CDeng","html_url":"https://github.com/Vincent-CDeng","followers_url":"https://api.github.com/users/Vincent-CDeng/followers","following_url":"https://api.github.com/users/Vincent-CDeng/following{/other_user}","gists_url":"https://api.github.com/users/Vincent-CDeng/gists{/gist_id}","starred_url":"https://api.github.com/users/Vincent-CDeng/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Vincent-CDeng/subscriptions","organizations_url":"https://api.github.com/users/Vincent-CDeng/orgs","repos_url":"https://api.github.com/users/Vincent-CDeng/repos","events_url":"https://api.github.com/users/Vincent-CDeng/events{/privacy}","received_events_url":"https://api.github.com/users/Vincent-CDeng/received_events","type":"User","site_admin":false},"labels":[{"id":466194901,"url":"https://api.github.com/repos/pusher/pusher-websocket-swift/labels/fix-proposed","name":"fix-proposed","color":"f9d0c4","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":10,"created_at":"2018-03-16T10:06:39Z","updated_at":"2018-03-25T20:21:16Z","closed_at":null,"author_association":"NONE","body":"    OCAuthMethod *authMethod = [[OCAuthMethod alloc] initWithAuthEndpoint:@\"endpoint\"];\r\n                                \r\n    OCPusherHost *host = [[OCPusherHost alloc]initWithHost:@\"host\"];\r\n    PusherClientOptions *options = [[PusherClientOptions alloc]\r\n                                    initWithOcAuthMethod:authMethod\r\n                                    attemptToReturnJSONObject:YES\r\n                                    autoReconnect:YES\r\n                                    ocHost:host\r\n                                    port:@8180\r\n                                    encrypted:NO];\r\n    _pusher = [[Pusher alloc] initWithAppKey:@\"secrete\" options:options];\r\n    \r\n//    _pusher = [[Pusher alloc] initWithKey:@\"232423\"];\r\n    [_pusher connect];\r\n    _pusher.connection.delegate = self;\r\n    \r\n    PusherChannel *myChannel = [_pusher subscribeWithChannelName:@\"channel\"];\r\n    [myChannel bindWithEventName:@\"event\" callback: ^void (NSDictionary *data) {\r\n        NSLog(@\"Subscribed!\");\r\n//        NSLog(@\"I can now access myId: %@\", myChannel.myId);\r\n//        NSLog(@\"And here are my channel members: %@\", myChannel.members);\r\n    }];\r\n\r\n\r\nuse this code to  can successfully establish connect ,but after about 60 seconds ,it will be disconnected and this is its log :message:[PUSHER DEBUG] Deliberate disconnection - skipping reconnect attempts"},"comment":{"url":"https://api.github.com/repos/pusher/pusher-websocket-swift/issues/comments/376000291","html_url":"https://github.com/pusher/pusher-websocket-swift/issues/176#issuecomment-376000291","issue_url":"https://api.github.com/repos/pusher/pusher-websocket-swift/issues/176","id":376000291,"user":{"login":"vostricov","id":6576981,"avatar_url":"https://avatars0.githubusercontent.com/u/6576981?v=4","gravatar_id":"","url":"https://api.github.com/users/vostricov","html_url":"https://github.com/vostricov","followers_url":"https://api.github.com/users/vostricov/followers","following_url":"https://api.github.com/users/vostricov/following{/other_user}","gists_url":"https://api.github.com/users/vostricov/gists{/gist_id}","starred_url":"https://api.github.com/users/vostricov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vostricov/subscriptions","organizations_url":"https://api.github.com/users/vostricov/orgs","repos_url":"https://api.github.com/users/vostricov/repos","events_url":"https://api.github.com/users/vostricov/events{/privacy}","received_events_url":"https://api.github.com/users/vostricov/received_events","type":"User","site_admin":false},"created_at":"2018-03-25T20:21:16Z","updated_at":"2018-03-25T20:21:16Z","author_association":"NONE","body":"@hamchapman You might need to update all 'import Starscream' to 'import StarscreamFork'. After that I could successfully compile the fixed pod. \r\nNow after receiving \"[PUSHER DEBUG] Websocket is disconnected but no error received\" the attemptReconnect() returns immediately because connectionState is still .connected. Should it be set to other value before attempting to reconnect?"}}
{"actor":{"display_login":"vostricov"}}