{"action":"created","comment":{"url":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls/comments/82700515","pull_request_review_id":3588809,"id":82700515,"diff_hunk":"@@ -947,9 +994,8 @@ def _get_layer_style_valid_rules(self, m, layer_style):\n             for sym in r.symbols:\n                 try:\n                     sym.avoid_edges = False\n-                except:\n-                    print(\n-                        \"**** Cant set avoid edges for rule\", r.name)\n+                except AttributeError:\n+                    logging.warning(\"Could not set avoid_edges for rule {}\".format(r.name))","path":"mapnik/printing/__init__.py","position":null,"original_position":369,"commit_id":"b6434cc5d10874fa4b370b91b897814f92f485d0","original_commit_id":"b6434cc5d10874fa4b370b91b897814f92f485d0","user":{"login":"rcoup","id":59874,"avatar_url":"https://avatars.githubusercontent.com/u/59874?v=3","gravatar_id":"","url":"https://api.github.com/users/rcoup","html_url":"https://github.com/rcoup","followers_url":"https://api.github.com/users/rcoup/followers","following_url":"https://api.github.com/users/rcoup/following{/other_user}","gists_url":"https://api.github.com/users/rcoup/gists{/gist_id}","starred_url":"https://api.github.com/users/rcoup/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rcoup/subscriptions","organizations_url":"https://api.github.com/users/rcoup/orgs","repos_url":"https://api.github.com/users/rcoup/repos","events_url":"https://api.github.com/users/rcoup/events{/privacy}","received_events_url":"https://api.github.com/users/rcoup/received_events","type":"User","site_admin":false},"body":"Create a logger in the top of the module or class:\r\n`L = logging.getLogger(\"mapnik.printing\")`\r\nthen use via:\r\n`L.warning(\"Could not set avoid_edges for rule %s\", r.name)`\r\n\r\nCalling `.warning()` on `logging` directly logs to the root logger, which causes all sorts of messes in applications (like dandelion) that are trying to filter and stream logging.","created_at":"2016-10-10T23:18:31Z","updated_at":"2016-10-10T23:18:31Z","html_url":"https://github.com/mbonnefoy/python-mapnik/pull/1#discussion_r82700515","pull_request_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls/comments/82700515"},"html":{"href":"https://github.com/mbonnefoy/python-mapnik/pull/1#discussion_r82700515"},"pull_request":{"href":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls/1","id":88148720,"html_url":"https://github.com/mbonnefoy/python-mapnik/pull/1","diff_url":"https://github.com/mbonnefoy/python-mapnik/pull/1.diff","patch_url":"https://github.com/mbonnefoy/python-mapnik/pull/1.patch","issue_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/issues/1","number":1,"state":"open","locked":false,"title":"WIP: Mapnik printing module refactoring","user":{"login":"mbonnefoy","id":9313546,"avatar_url":"https://avatars.githubusercontent.com/u/9313546?v=3","gravatar_id":"","url":"https://api.github.com/users/mbonnefoy","html_url":"https://github.com/mbonnefoy","followers_url":"https://api.github.com/users/mbonnefoy/followers","following_url":"https://api.github.com/users/mbonnefoy/following{/other_user}","gists_url":"https://api.github.com/users/mbonnefoy/gists{/gist_id}","starred_url":"https://api.github.com/users/mbonnefoy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbonnefoy/subscriptions","organizations_url":"https://api.github.com/users/mbonnefoy/orgs","repos_url":"https://api.github.com/users/mbonnefoy/repos","events_url":"https://api.github.com/users/mbonnefoy/events{/privacy}","received_events_url":"https://api.github.com/users/mbonnefoy/received_events","type":"User","site_admin":false},"body":"- [x]  Move helpers out of the printing module\r\n- [x]  Split large methods into smaller ones and reduce repetition\r\n- [x]  Improve docstrings and comments\r\n- [ ]  reduce cairo contexts relative translations for improved flexibility","created_at":"2016-10-05T20:16:50Z","updated_at":"2016-10-10T23:22:19Z","closed_at":null,"merged_at":null,"merge_commit_sha":"c93e5c9ebfad32af2c4f3347006449604d781e30","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls/1/commits","review_comments_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls/1/comments","review_comment_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/issues/1/comments","statuses_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/statuses/b6434cc5d10874fa4b370b91b897814f92f485d0","head":{"label":"mbonnefoy:printing_refactoring","ref":"printing_refactoring","sha":"b6434cc5d10874fa4b370b91b897814f92f485d0","user":{"login":"mbonnefoy","id":9313546,"avatar_url":"https://avatars.githubusercontent.com/u/9313546?v=3","gravatar_id":"","url":"https://api.github.com/users/mbonnefoy","html_url":"https://github.com/mbonnefoy","followers_url":"https://api.github.com/users/mbonnefoy/followers","following_url":"https://api.github.com/users/mbonnefoy/following{/other_user}","gists_url":"https://api.github.com/users/mbonnefoy/gists{/gist_id}","starred_url":"https://api.github.com/users/mbonnefoy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbonnefoy/subscriptions","organizations_url":"https://api.github.com/users/mbonnefoy/orgs","repos_url":"https://api.github.com/users/mbonnefoy/repos","events_url":"https://api.github.com/users/mbonnefoy/events{/privacy}","received_events_url":"https://api.github.com/users/mbonnefoy/received_events","type":"User","site_admin":false},"repo":{"id":69400044,"name":"python-mapnik","full_name":"mbonnefoy/python-mapnik","owner":{"login":"mbonnefoy","id":9313546,"avatar_url":"https://avatars.githubusercontent.com/u/9313546?v=3","gravatar_id":"","url":"https://api.github.com/users/mbonnefoy","html_url":"https://github.com/mbonnefoy","followers_url":"https://api.github.com/users/mbonnefoy/followers","following_url":"https://api.github.com/users/mbonnefoy/following{/other_user}","gists_url":"https://api.github.com/users/mbonnefoy/gists{/gist_id}","starred_url":"https://api.github.com/users/mbonnefoy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbonnefoy/subscriptions","organizations_url":"https://api.github.com/users/mbonnefoy/orgs","repos_url":"https://api.github.com/users/mbonnefoy/repos","events_url":"https://api.github.com/users/mbonnefoy/events{/privacy}","received_events_url":"https://api.github.com/users/mbonnefoy/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mbonnefoy/python-mapnik","description":"Python bindings for mapnik","fork":true,"url":"https://api.github.com/repos/mbonnefoy/python-mapnik","forks_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/forks","keys_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/teams","hooks_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/hooks","issue_events_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/issues/events{/number}","events_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/events","assignees_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/assignees{/user}","branches_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/branches{/branch}","tags_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/tags","blobs_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/git/refs{/sha}","trees_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/statuses/{sha}","languages_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/languages","stargazers_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/stargazers","contributors_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/contributors","subscribers_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/subscribers","subscription_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/subscription","commits_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/commits{/sha}","git_commits_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/git/commits{/sha}","comments_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/comments{/number}","issue_comment_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/issues/comments{/number}","contents_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/contents/{+path}","compare_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/merges","archive_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/downloads","issues_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/issues{/number}","pulls_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls{/number}","milestones_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/milestones{/number}","notifications_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/labels{/name}","releases_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/releases{/id}","deployments_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/deployments","created_at":"2016-09-27T21:26:08Z","updated_at":"2016-09-27T21:26:09Z","pushed_at":"2016-10-10T00:12:17Z","git_url":"git://github.com/mbonnefoy/python-mapnik.git","ssh_url":"git@github.com:mbonnefoy/python-mapnik.git","clone_url":"https://github.com/mbonnefoy/python-mapnik.git","svn_url":"https://github.com/mbonnefoy/python-mapnik","homepage":null,"size":137642,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"mbonnefoy:master","ref":"master","sha":"541fd962d4fc99d50ec472af6ddccfdbf98cff37","user":{"login":"mbonnefoy","id":9313546,"avatar_url":"https://avatars.githubusercontent.com/u/9313546?v=3","gravatar_id":"","url":"https://api.github.com/users/mbonnefoy","html_url":"https://github.com/mbonnefoy","followers_url":"https://api.github.com/users/mbonnefoy/followers","following_url":"https://api.github.com/users/mbonnefoy/following{/other_user}","gists_url":"https://api.github.com/users/mbonnefoy/gists{/gist_id}","starred_url":"https://api.github.com/users/mbonnefoy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbonnefoy/subscriptions","organizations_url":"https://api.github.com/users/mbonnefoy/orgs","repos_url":"https://api.github.com/users/mbonnefoy/repos","events_url":"https://api.github.com/users/mbonnefoy/events{/privacy}","received_events_url":"https://api.github.com/users/mbonnefoy/received_events","type":"User","site_admin":false},"repo":{"id":69400044,"name":"python-mapnik","full_name":"mbonnefoy/python-mapnik","owner":{"login":"mbonnefoy","id":9313546,"avatar_url":"https://avatars.githubusercontent.com/u/9313546?v=3","gravatar_id":"","url":"https://api.github.com/users/mbonnefoy","html_url":"https://github.com/mbonnefoy","followers_url":"https://api.github.com/users/mbonnefoy/followers","following_url":"https://api.github.com/users/mbonnefoy/following{/other_user}","gists_url":"https://api.github.com/users/mbonnefoy/gists{/gist_id}","starred_url":"https://api.github.com/users/mbonnefoy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mbonnefoy/subscriptions","organizations_url":"https://api.github.com/users/mbonnefoy/orgs","repos_url":"https://api.github.com/users/mbonnefoy/repos","events_url":"https://api.github.com/users/mbonnefoy/events{/privacy}","received_events_url":"https://api.github.com/users/mbonnefoy/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mbonnefoy/python-mapnik","description":"Python bindings for mapnik","fork":true,"url":"https://api.github.com/repos/mbonnefoy/python-mapnik","forks_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/forks","keys_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/teams","hooks_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/hooks","issue_events_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/issues/events{/number}","events_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/events","assignees_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/assignees{/user}","branches_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/branches{/branch}","tags_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/tags","blobs_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/git/refs{/sha}","trees_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/statuses/{sha}","languages_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/languages","stargazers_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/stargazers","contributors_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/contributors","subscribers_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/subscribers","subscription_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/subscription","commits_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/commits{/sha}","git_commits_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/git/commits{/sha}","comments_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/comments{/number}","issue_comment_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/issues/comments{/number}","contents_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/contents/{+path}","compare_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/merges","archive_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/downloads","issues_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/issues{/number}","pulls_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls{/number}","milestones_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/milestones{/number}","notifications_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/labels{/name}","releases_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/releases{/id}","deployments_url":"https://api.github.com/repos/mbonnefoy/python-mapnik/deployments","created_at":"2016-09-27T21:26:08Z","updated_at":"2016-09-27T21:26:09Z","pushed_at":"2016-10-10T00:12:17Z","git_url":"git://github.com/mbonnefoy/python-mapnik.git","ssh_url":"git@github.com:mbonnefoy/python-mapnik.git","clone_url":"https://github.com/mbonnefoy/python-mapnik.git","svn_url":"https://github.com/mbonnefoy/python-mapnik","homepage":null,"size":137642,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls/1"},"html":{"href":"https://github.com/mbonnefoy/python-mapnik/pull/1"},"issue":{"href":"https://api.github.com/repos/mbonnefoy/python-mapnik/issues/1"},"comments":{"href":"https://api.github.com/repos/mbonnefoy/python-mapnik/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mbonnefoy/python-mapnik/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/mbonnefoy/python-mapnik/statuses/b6434cc5d10874fa4b370b91b897814f92f485d0"}}}}
{"actor":{"display_login":"rcoup"}}