{"action":"created","issue":{"url":"https://api.github.com/repos/peterbe/premailer/issues/176","repository_url":"https://api.github.com/repos/peterbe/premailer","labels_url":"https://api.github.com/repos/peterbe/premailer/issues/176/labels{/name}","comments_url":"https://api.github.com/repos/peterbe/premailer/issues/176/comments","events_url":"https://api.github.com/repos/peterbe/premailer/issues/176/events","html_url":"https://github.com/peterbe/premailer/pull/176","id":178119074,"number":176,"title":"Raising an error on external style 404s","user":{"login":"rclmenezes","id":736775,"avatar_url":"https://avatars.githubusercontent.com/u/736775?v=3","gravatar_id":"","url":"https://api.github.com/users/rclmenezes","html_url":"https://github.com/rclmenezes","followers_url":"https://api.github.com/users/rclmenezes/followers","following_url":"https://api.github.com/users/rclmenezes/following{/other_user}","gists_url":"https://api.github.com/users/rclmenezes/gists{/gist_id}","starred_url":"https://api.github.com/users/rclmenezes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rclmenezes/subscriptions","organizations_url":"https://api.github.com/users/rclmenezes/orgs","repos_url":"https://api.github.com/users/rclmenezes/repos","events_url":"https://api.github.com/users/rclmenezes/events{/privacy}","received_events_url":"https://api.github.com/users/rclmenezes/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-09-20T17:07:27Z","updated_at":"2016-09-21T13:48:50Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/peterbe/premailer/pulls/176","html_url":"https://github.com/peterbe/premailer/pull/176","diff_url":"https://github.com/peterbe/premailer/pull/176.diff","patch_url":"https://github.com/peterbe/premailer/pull/176.patch"},"body":"If you give premailer an external stylesheet that 404s, it should raise an ExternalNotFoundError. Otherwise, it will attempt to parse the 404 page as a CSS file and give you some funky errors."},"comment":{"url":"https://api.github.com/repos/peterbe/premailer/issues/comments/248617849","html_url":"https://github.com/peterbe/premailer/pull/176#issuecomment-248617849","issue_url":"https://api.github.com/repos/peterbe/premailer/issues/176","id":248617849,"user":{"login":"peterbe","id":26739,"avatar_url":"https://avatars.githubusercontent.com/u/26739?v=3","gravatar_id":"","url":"https://api.github.com/users/peterbe","html_url":"https://github.com/peterbe","followers_url":"https://api.github.com/users/peterbe/followers","following_url":"https://api.github.com/users/peterbe/following{/other_user}","gists_url":"https://api.github.com/users/peterbe/gists{/gist_id}","starred_url":"https://api.github.com/users/peterbe/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/peterbe/subscriptions","organizations_url":"https://api.github.com/users/peterbe/orgs","repos_url":"https://api.github.com/users/peterbe/repos","events_url":"https://api.github.com/users/peterbe/events{/privacy}","received_events_url":"https://api.github.com/users/peterbe/received_events","type":"User","site_admin":false},"created_at":"2016-09-21T13:48:50Z","updated_at":"2016-09-21T13:48:50Z","body":"This might need to be optional. I.e. make it so that instead of trying to parse the response body during a 404 it **ignores** it. Perhaps with a warning. That's what `cssutils` does when it encounters a bad CSS selector it doesn't understand. \r\nHowever, raising an error is probably a good default. \r\n\r\nAlso, I wonder if the conditional should instead be `if r.status != 200: raise ...`. \r\nA CSS file might sit on a CDN or something that is temporarily down. What do you think?"}}
{"actor":{"display_login":"peterbe"}}