{"action":"created","issue":{"url":"https://api.github.com/repos/datagovuk/ckanext-datapreview/issues/9","labels_url":"https://api.github.com/repos/datagovuk/ckanext-datapreview/issues/9/labels{/name}","comments_url":"https://api.github.com/repos/datagovuk/ckanext-datapreview/issues/9/comments","events_url":"https://api.github.com/repos/datagovuk/ckanext-datapreview/issues/9/events","html_url":"https://github.com/datagovuk/ckanext-datapreview/pull/9","id":98733699,"number":9,"title":"[WIP] Check the remote mimetype before rendering","user":{"login":"rossjones","id":118063,"avatar_url":"https://avatars.githubusercontent.com/u/118063?v=3","gravatar_id":"","url":"https://api.github.com/users/rossjones","html_url":"https://github.com/rossjones","followers_url":"https://api.github.com/users/rossjones/followers","following_url":"https://api.github.com/users/rossjones/following{/other_user}","gists_url":"https://api.github.com/users/rossjones/gists{/gist_id}","starred_url":"https://api.github.com/users/rossjones/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rossjones/subscriptions","organizations_url":"https://api.github.com/users/rossjones/orgs","repos_url":"https://api.github.com/users/rossjones/repos","events_url":"https://api.github.com/users/rossjones/events{/privacy}","received_events_url":"https://api.github.com/users/rossjones/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-08-03T12:30:55Z","updated_at":"2015-08-03T15:32:17Z","closed_at":"2015-08-03T15:32:17Z","pull_request":{"url":"https://api.github.com/repos/datagovuk/ckanext-datapreview/pulls/9","html_url":"https://github.com/datagovuk/ckanext-datapreview/pull/9","diff_url":"https://github.com/datagovuk/ckanext-datapreview/pull/9.diff","patch_url":"https://github.com/datagovuk/ckanext-datapreview/pull/9.patch"},"body":"Datapreview accepts the format sent in the query params is correct, and\r\noften it isn't.  If when requesting the data the preview is returning a\r\nnon-displayable mimetype, then it now errors.\r\n\r\ne.g. client sends format=csv, if fetching the data determines it is actually \r\ntext/plain then it is not rendered.\r\n\r\nThis should resolve issues where someone points to a CSV that now \r\nresolves to HTML (because there's no decent 404 handler for instance).\r\n"},"comment":{"url":"https://api.github.com/repos/datagovuk/ckanext-datapreview/issues/comments/127278472","html_url":"https://github.com/datagovuk/ckanext-datapreview/pull/9#issuecomment-127278472","issue_url":"https://api.github.com/repos/datagovuk/ckanext-datapreview/issues/9","id":127278472,"user":{"login":"rossjones","id":118063,"avatar_url":"https://avatars.githubusercontent.com/u/118063?v=3","gravatar_id":"","url":"https://api.github.com/users/rossjones","html_url":"https://github.com/rossjones","followers_url":"https://api.github.com/users/rossjones/followers","following_url":"https://api.github.com/users/rossjones/following{/other_user}","gists_url":"https://api.github.com/users/rossjones/gists{/gist_id}","starred_url":"https://api.github.com/users/rossjones/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rossjones/subscriptions","organizations_url":"https://api.github.com/users/rossjones/orgs","repos_url":"https://api.github.com/users/rossjones/repos","events_url":"https://api.github.com/users/rossjones/events{/privacy}","received_events_url":"https://api.github.com/users/rossjones/received_events","type":"User","site_admin":false},"created_at":"2015-08-03T15:32:17Z","updated_at":"2015-08-03T15:32:17Z","body":"Closing this in favour of a PR that fixes the actual problem."}}