{"action":"created","issue":{"url":"https://api.github.com/repos/phoenixframework/phoenix/issues/2018","repository_url":"https://api.github.com/repos/phoenixframework/phoenix","labels_url":"https://api.github.com/repos/phoenixframework/phoenix/issues/2018/labels{/name}","comments_url":"https://api.github.com/repos/phoenixframework/phoenix/issues/2018/comments","events_url":"https://api.github.com/repos/phoenixframework/phoenix/issues/2018/events","html_url":"https://github.com/phoenixframework/phoenix/issues/2018","id":192939098,"number":2018,"title":"Nothing happens when joining from iOS","user":{"login":"dmdque","id":5205766,"avatar_url":"https://avatars.githubusercontent.com/u/5205766?v=3","gravatar_id":"","url":"https://api.github.com/users/dmdque","html_url":"https://github.com/dmdque","followers_url":"https://api.github.com/users/dmdque/followers","following_url":"https://api.github.com/users/dmdque/following{/other_user}","gists_url":"https://api.github.com/users/dmdque/gists{/gist_id}","starred_url":"https://api.github.com/users/dmdque/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dmdque/subscriptions","organizations_url":"https://api.github.com/users/dmdque/orgs","repos_url":"https://api.github.com/users/dmdque/repos","events_url":"https://api.github.com/users/dmdque/events{/privacy}","received_events_url":"https://api.github.com/users/dmdque/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-12-01T19:27:39Z","updated_at":"2016-12-01T19:51:21Z","closed_at":null,"body":"### Environment\r\n\r\n* Elixir version (elixir -v): 1.3.4\r\n* Phoenix version (mix deps):\r\n\r\n    * connection 1.0.4 (Hex package) (mix)\r\n      locked at 1.0.4 (connection) a1cae722\r\n      ok\r\n    * fs 0.9.1 (Hex package) (rebar)\r\n      locked at 0.9.2 (fs) ed17036c\r\n      ok\r\n    * gettext 0.12.1 (Hex package) (mix)\r\n      locked at 0.12.1 (gettext) c0624f52\r\n      ok\r\n    * ranch 1.2.1 (Hex package) (rebar)\r\n      locked at 1.2.1 (ranch) a6fb992c\r\n      ok\r\n    * poolboy 1.5.1 (Hex package) (rebar)\r\n      locked at 1.5.1 (poolboy) 6b461639\r\n      ok\r\n    * decimal 1.3.1 (Hex package) (mix)\r\n      locked at 1.3.1 (decimal) 157b3ced\r\n      ok\r\n    * poison 2.2.0 (Hex package) (mix)\r\n      locked at 2.2.0 (poison) 4763b69a\r\n      ok\r\n    * db_connection 1.1.0 (Hex package) (mix)\r\n      locked at 1.1.0 (db_connection) b2b88db6\r\n      ok\r\n    * phoenix_pubsub 1.0.1 (Hex package) (mix)\r\n      locked at 1.0.1 (phoenix_pubsub) c10ddf62\r\n      ok\r\n    * cowlib 1.0.2 (Hex package) (rebar)\r\n      locked at 1.0.2 (cowlib) 9d769a1d\r\n      ok\r\n    * cowboy 1.0.4 (Hex package) (rebar)\r\n      locked at 1.0.4 (cowboy) a324a8df\r\n      ok\r\n    * mime 1.0.1 (Hex package) (mix)\r\n      locked at 1.0.1 (mime) 05c39385\r\n      ok\r\n    * plug 1.2.2 (Hex package) (mix)\r\n      locked at 1.2.2 (plug) cfbda521\r\n      ok\r\n    * phoenix_html 2.8.0 (Hex package) (mix)\r\n      locked at 2.8.0 (phoenix_html) 777598a4\r\n      ok\r\n    * phoenix 1.2.1 (Hex package) (mix)\r\n      locked at 1.2.1 (phoenix) 6dc59224\r\n      ok\r\n    * phoenix_live_reload 1.0.5 (Hex package) (mix)\r\n      locked at 1.0.5 (phoenix_live_reload) 829218c4\r\n      ok\r\n    * postgrex 0.12.1 (Hex package) (mix)\r\n      locked at 0.12.1 (postgrex) 2f8b46cb\r\n      ok\r\n    * ecto 2.0.6 (Hex package) (mix)\r\n      locked at 2.0.6 (ecto) 9dcbf819\r\n      ok\r\n    * phoenix_ecto 3.0.1 (Hex package) (mix)\r\n      locked at 3.0.1 (phoenix_ecto) 42eb486e\r\n      ok\r\n\r\n* NodeJS version (node -v): v6.7.0\r\n* NPM version (npm -v): 3.10.7\r\n* Operating system: macOS Sierra 10.12.1\r\n\r\n### Expected behavior\r\nJoin room from iOS and see logs on the server to confirm that the room has been joined.\r\n\r\n### Actual behavior\r\nJoin room from iOS, no logs on server.\r\n\r\n### Description\r\nI'm using a simple Phoenix instance, and have a simple channel join event working as expected with a JS client. I'm using the following on iOS [SwiftPhoenixClient](https://github.com/davidstump/SwiftPhoenixClient):\r\n\r\n    let socket = Socket(domainAndPort: \"localhost:4000\", path: \"socket\", transport: \"websocket\")\r\n    socket.join(topic: \"room:lobby\", message: Message(subject: \"status\", body: \"joining\")) { channel in\r\n        let channel = channel as! Channel\r\n        print(\"join\")\r\n    }\r\n\r\nBut nothing is logged on the server. I also tried with [Birdsong](https://github.com/sjrmanning/Birdsong) with the same result:\r\n\r\n        let socket = Birdsong.Socket(url: URL(string: \"http://10.88.111.2:4000/socket/websocket\")!)\r\n        socket.connect()\r\n\r\nI'm watching the traffic going through the server's port 4000 (`sudo tcpdump port 4000`) and am seeing some packets flow every time I trigger the above code. eg. (`10.88.111.2` is the server's IP, and `10.88.111.30` is the iOS client's IP)\r\n\r\n    // With SwiftPhoenixClient\r\n    14:21:48.161241 IP 10.88.111.30.61762 > 10.88.111.2.terabase: Flags [S], seq 110794316, win 65535, options [mss 1460,nop,wscale 5,nop,nop,TS val 861181191 ecr 0,sackOK,eol], length 0\r\n    14:21:48.161393 IP 10.88.111.2.terabase > 10.88.111.30.61762: Flags [S.], seq 1986623172, ack 110794317, win 65535, options [mss 1460,nop,wscale 5,nop,nop,TS val 607536416 ecr 861181191,sackOK,eol], length 0\r\n    14:21:48.163864 IP 10.88.111.30.61762 > 10.88.111.2.terabase: Flags [R], seq 110794317, win 0, length 0\r\n\r\n    // With Birdsong\r\n    14:21:51.362180 IP 10.88.111.30.61763 > 10.88.111.2.terabase: Flags [S], seq 1908544453, win 65535, options [mss 1460,nop,wscale 5,nop,nop,TS val 861184367 ecr 0,sackOK,eol], length 0\r\n    14:21:51.362332 IP 10.88.111.2.terabase > 10.88.111.30.61763: Flags [S.], seq 31220766, ack 1908544454, win 65535, options [mss 1460,nop,wscale 5,nop,nop,TS val 607539593 ecr 861184367,sackOK,eol], length 0\r\n    14:21:51.365562 IP 10.88.111.30.61763 > 10.88.111.2.terabase: Flags [R], seq 1908544454, win 0, length 0\r\n\r\nI've also created a ticket here: https://github.com/davidstump/SwiftPhoenixClient/issues/61. But it seems unlikely that the client is the issue since this happens with two of them."},"comment":{"url":"https://api.github.com/repos/phoenixframework/phoenix/issues/comments/264275535","html_url":"https://github.com/phoenixframework/phoenix/issues/2018#issuecomment-264275535","issue_url":"https://api.github.com/repos/phoenixframework/phoenix/issues/2018","id":264275535,"user":{"login":"dmdque","id":5205766,"avatar_url":"https://avatars.githubusercontent.com/u/5205766?v=3","gravatar_id":"","url":"https://api.github.com/users/dmdque","html_url":"https://github.com/dmdque","followers_url":"https://api.github.com/users/dmdque/followers","following_url":"https://api.github.com/users/dmdque/following{/other_user}","gists_url":"https://api.github.com/users/dmdque/gists{/gist_id}","starred_url":"https://api.github.com/users/dmdque/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dmdque/subscriptions","organizations_url":"https://api.github.com/users/dmdque/orgs","repos_url":"https://api.github.com/users/dmdque/repos","events_url":"https://api.github.com/users/dmdque/events{/privacy}","received_events_url":"https://api.github.com/users/dmdque/received_events","type":"User","site_admin":false},"created_at":"2016-12-01T19:51:21Z","updated_at":"2016-12-01T19:51:21Z","body":"Yes it does. Joining channels and chatting works fine with https://github.com/chrismccord/phoenix_chat_example. But using the same backend with an iOS client doesn't."}}
{"actor":{"display_login":"dmdque"}}