{"action":"created","issue":{"url":"https://api.github.com/repos/jlguardi/yowsup/issues/14","repository_url":"https://api.github.com/repos/jlguardi/yowsup","labels_url":"https://api.github.com/repos/jlguardi/yowsup/issues/14/labels{/name}","comments_url":"https://api.github.com/repos/jlguardi/yowsup/issues/14/comments","events_url":"https://api.github.com/repos/jlguardi/yowsup/issues/14/events","html_url":"https://github.com/jlguardi/yowsup/issues/14","id":144320863,"number":14,"title":"[TODO] Fix error sending location","user":{"login":"cfenollosa","id":2249551,"avatar_url":"https://avatars.githubusercontent.com/u/2249551?v=3","gravatar_id":"","url":"https://api.github.com/users/cfenollosa","html_url":"https://github.com/cfenollosa","followers_url":"https://api.github.com/users/cfenollosa/followers","following_url":"https://api.github.com/users/cfenollosa/following{/other_user}","gists_url":"https://api.github.com/users/cfenollosa/gists{/gist_id}","starred_url":"https://api.github.com/users/cfenollosa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cfenollosa/subscriptions","organizations_url":"https://api.github.com/users/cfenollosa/orgs","repos_url":"https://api.github.com/users/cfenollosa/repos","events_url":"https://api.github.com/users/cfenollosa/events{/privacy}","received_events_url":"https://api.github.com/users/cfenollosa/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2016-03-29T16:42:48Z","updated_at":"2016-03-31T07:47:21Z","closed_at":"2016-03-30T12:39:20Z","body":"Hi @jlguardi,\r\n\r\nI updated the code to the latest master (plus axolotl dev) and now location messages drop an error when sending:\r\n\r\n```\r\nUnhandled exception in thread started by <bound method Layer.send_reply_delayed of <layer_whatsapp.layer.Layer object at 0x7f283f933c10>>\r\nTraceback (most recent call last):\r\n  File \"/home/astx/whatsbot/whatsapp-bot/layer_whatsapp/layer.py\", line 170, in send_reply_delayed\r\n    self.toLower(entity)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/__init__.py\", line 79, in toLower\r\n    self.__lower.send(data)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/__init__.py\", line 192, in send\r\n    s.send(data)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/__init__.py\", line 130, in send\r\n    send(entity)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/protocol_media/layer.py\", line 35, in sendMessageEntity\r\n    self.entityToLower(entity)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/__init__.py\", line 134, in entityToLower\r\n    self.toLower(entity.toProtocolTreeNode())\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/__init__.py\", line 79, in toLower\r\n    self.__lower.send(data)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/axolotl/layer.py\", line 120, in send\r\n    self.handlePlaintextNode(node)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/axolotl/layer.py\", line 188, in handlePlaintextNode\r\n    messageData = self.serializeToProtobuf(node) if v2 else node.getChild(\"body\").getData()\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/axolotl/layer.py\", line 423, in serializeToProtobuf\r\n    return self.serializeMediaToProtobuf(node.getChild(\"media\"))\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/axolotl/layer.py\", line 437, in serializeMediaToProtobuf\r\n    return self.serializeLocationToProtobuf(mediaNode)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/axolotl/layer.py\", line 446, in serializeLocationToProtobuf\r\n    location_message.degress_latitude = float(mediaNode[\"latitude\"])\r\nAttributeError: 'LocationMessage' object has no attribute 'degress_latitude'\r\n```"},"comment":{"url":"https://api.github.com/repos/jlguardi/yowsup/issues/comments/203802619","html_url":"https://github.com/jlguardi/yowsup/issues/14#issuecomment-203802619","issue_url":"https://api.github.com/repos/jlguardi/yowsup/issues/14","id":203802619,"user":{"login":"cfenollosa","id":2249551,"avatar_url":"https://avatars.githubusercontent.com/u/2249551?v=3","gravatar_id":"","url":"https://api.github.com/users/cfenollosa","html_url":"https://github.com/cfenollosa","followers_url":"https://api.github.com/users/cfenollosa/followers","following_url":"https://api.github.com/users/cfenollosa/following{/other_user}","gists_url":"https://api.github.com/users/cfenollosa/gists{/gist_id}","starred_url":"https://api.github.com/users/cfenollosa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cfenollosa/subscriptions","organizations_url":"https://api.github.com/users/cfenollosa/orgs","repos_url":"https://api.github.com/users/cfenollosa/repos","events_url":"https://api.github.com/users/cfenollosa/events{/privacy}","received_events_url":"https://api.github.com/users/cfenollosa/received_events","type":"User","site_admin":false},"created_at":"2016-03-31T07:47:21Z","updated_at":"2016-03-31T07:47:21Z","body":"Hi, it's still not working, you need to change lines 525 and 526 in `axolotl/layer.py`, \"degress\" to \"degrees\" too, and then it drops more errors:\r\n\r\n```\r\nUnhandled exception in thread started by <bound method LayerRacc.send_reply_delayed of <layer_whatsapp.layer_racc.LayerRacc object at 0x7f692b75a710>>\r\nTraceback (most recent call last):\r\n  File \"/home/astx/whatsbot/whatsapp-bot/layer_whatsapp/layer_racc.py\", line 170, in send_reply_delayed\r\n    self.toLower(entity)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/__init__.py\", line 79, in toLower\r\n    self.__lower.send(data)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/__init__.py\", line 192, in send\r\n    s.send(data)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/__init__.py\", line 130, in send\r\n    send(entity)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/protocol_media/layer.py\", line 37, in sendMessageEntity\r\n    self.entityToLower(entity)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/__init__.py\", line 134, in entityToLower\r\n    self.toLower(entity.toProtocolTreeNode())\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/__init__.py\", line 79, in toLower\r\n    self.__lower.send(data)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/axolotl/layer.py\", line 122, in send\r\n    self.handlePlaintextNode(node)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/axolotl/layer.py\", line 190, in handlePlaintextNode\r\n    messageData = self.serializeToProtobuf(node) if v2 else node.getChild(\"body\").getData()\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/axolotl/layer.py\", line 502, in serializeToProtobuf\r\n    return self.serializeMediaToProtobuf(node.getChild(\"media\"))\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/axolotl/layer.py\", line 516, in serializeMediaToProtobuf\r\n    return self.serializeLocationToProtobuf(mediaNode)\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/yowsup2-2.4.48-py2.7.egg/yowsup/layers/axolotl/layer.py\", line 532, in serializeLocationToProtobuf\r\n    return m.SerializeToString()\r\n  File \"/home/astx/whatsbot/env/local/lib/python2.7/site-packages/google/protobuf/internal/python_message.py\", line 831, in SerializeToString\r\n    self.DESCRIPTOR.full_name, ','.join(self.FindInitializationErrors())))\r\ngoogle.protobuf.message.EncodeError: Message com.whatsapp.proto.Message is missing required fields: location_message.jpeg_thumbnail\r\n```"}}