{"action":"opened","issue":{"url":"https://api.github.com/repos/kivy-garden/garden.mapview/issues/55","repository_url":"https://api.github.com/repos/kivy-garden/garden.mapview","labels_url":"https://api.github.com/repos/kivy-garden/garden.mapview/issues/55/labels{/name}","comments_url":"https://api.github.com/repos/kivy-garden/garden.mapview/issues/55/comments","events_url":"https://api.github.com/repos/kivy-garden/garden.mapview/issues/55/events","html_url":"https://github.com/kivy-garden/garden.mapview/issues/55","id":373172367,"node_id":"MDU6SXNzdWUzNzMxNzIzNjc=","number":55,"title":"insert_marker incompatible with Python 3","user":{"login":"alfajet","id":5763896,"node_id":"MDQ6VXNlcjU3NjM4OTY=","avatar_url":"https://avatars2.githubusercontent.com/u/5763896?v=4","gravatar_id":"","url":"https://api.github.com/users/alfajet","html_url":"https://github.com/alfajet","followers_url":"https://api.github.com/users/alfajet/followers","following_url":"https://api.github.com/users/alfajet/following{/other_user}","gists_url":"https://api.github.com/users/alfajet/gists{/gist_id}","starred_url":"https://api.github.com/users/alfajet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alfajet/subscriptions","organizations_url":"https://api.github.com/users/alfajet/orgs","repos_url":"https://api.github.com/users/alfajet/repos","events_url":"https://api.github.com/users/alfajet/events{/privacy}","received_events_url":"https://api.github.com/users/alfajet/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-10-23T19:52:42Z","updated_at":"2018-10-23T19:52:42Z","closed_at":null,"author_association":"NONE","body":"In https://github.com/kivy-garden/garden.mapview/blob/master/mapview/view.py#L206\r\nlambda (i, m) is not  a valid syntax in Python 3\r\nas suggested here: https://stackoverflow.com/a/21893097\r\nI have modified my local copy of this function as follow:\r\n```python\r\n    def insert_marker(self, marker, **kwargs):\r\n        if self.order_marker_by_latitude:\r\n            i_m = (i, m)\r\n            before = list(takewhile(\r\n                lambda i_m: i[1].lat < marker.lat,\r\n                enumerate(self.children)\r\n            ))\r\n            if before:\r\n                kwargs['index'] = before[-1][0] + 1\r\n\r\n        super(MarkerMapLayer, self).add_widget(marker, **kwargs)\r\n```\r\nthe variable i doesn't seem to be used, perhaps this could be further simplified."}}
{"actor":{"display_login":"alfajet"}}