{"action":"created","issue":{"url":"https://api.github.com/repos/flask-restful/flask-restful/issues/387","labels_url":"https://api.github.com/repos/flask-restful/flask-restful/issues/387/labels{/name}","comments_url":"https://api.github.com/repos/flask-restful/flask-restful/issues/387/comments","events_url":"https://api.github.com/repos/flask-restful/flask-restful/issues/387/events","html_url":"https://github.com/flask-restful/flask-restful/issues/387","id":54098446,"number":387,"title":"reqparse.Argument","user":{"login":"kenjones-cisco","id":7967510,"avatar_url":"https://avatars.githubusercontent.com/u/7967510?v=3","gravatar_id":"","url":"https://api.github.com/users/kenjones-cisco","html_url":"https://github.com/kenjones-cisco","followers_url":"https://api.github.com/users/kenjones-cisco/followers","following_url":"https://api.github.com/users/kenjones-cisco/following{/other_user}","gists_url":"https://api.github.com/users/kenjones-cisco/gists{/gist_id}","starred_url":"https://api.github.com/users/kenjones-cisco/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kenjones-cisco/subscriptions","organizations_url":"https://api.github.com/users/kenjones-cisco/orgs","repos_url":"https://api.github.com/users/kenjones-cisco/repos","events_url":"https://api.github.com/users/kenjones-cisco/events{/privacy}","received_events_url":"https://api.github.com/users/kenjones-cisco/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/flask-restful/flask-restful/labels/reqparse","name":"reqparse","color":"fbca04"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/flask-restful/flask-restful/milestones/4","labels_url":"https://api.github.com/repos/flask-restful/flask-restful/milestones/4/labels","id":936738,"number":4,"title":"1.0.0","description":"","creator":{"login":"joshfriend","id":885137,"avatar_url":"https://avatars.githubusercontent.com/u/885137?v=3","gravatar_id":"","url":"https://api.github.com/users/joshfriend","html_url":"https://github.com/joshfriend","followers_url":"https://api.github.com/users/joshfriend/followers","following_url":"https://api.github.com/users/joshfriend/following{/other_user}","gists_url":"https://api.github.com/users/joshfriend/gists{/gist_id}","starred_url":"https://api.github.com/users/joshfriend/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joshfriend/subscriptions","organizations_url":"https://api.github.com/users/joshfriend/orgs","repos_url":"https://api.github.com/users/joshfriend/repos","events_url":"https://api.github.com/users/joshfriend/events{/privacy}","received_events_url":"https://api.github.com/users/joshfriend/received_events","type":"User","site_admin":false},"open_issues":8,"closed_issues":0,"state":"open","created_at":"2015-01-15T13:14:43Z","updated_at":"2015-01-16T18:02:55Z","due_on":"2015-01-31T05:00:00Z","closed_at":null},"comments":8,"created_at":"2015-01-12T19:52:26Z","updated_at":"2015-01-16T20:03:11Z","closed_at":null,"body":"The default location is (json, values). The call to `value = getattr(request, l, None)` where `l = 'json' `results in a `BadRequest()` exception from flask if there was no data to parse.\r\n\r\n`flask.wrappers.Request.get_json` has a flag silent that will result in `None` being returned instead of throwing the `BadRequest()` exception when there is no data to parse. \r\n\r\nOptions:\r\n- calls to `get_json` uses `silent = True`\r\n- a check if data exists prior to making the call to `get_json`\r\n- an option for flask-restful consumers to specify `silent = True`\r\n- a bug request to Flask proper to check for if data prior to performing `json.loads`\r\n\r\n "},"comment":{"url":"https://api.github.com/repos/flask-restful/flask-restful/issues/comments/70313508","html_url":"https://github.com/flask-restful/flask-restful/issues/387#issuecomment-70313508","issue_url":"https://api.github.com/repos/flask-restful/flask-restful/issues/387","id":70313508,"user":{"login":"RonnyPfannschmidt","id":156838,"avatar_url":"https://avatars.githubusercontent.com/u/156838?v=3","gravatar_id":"","url":"https://api.github.com/users/RonnyPfannschmidt","html_url":"https://github.com/RonnyPfannschmidt","followers_url":"https://api.github.com/users/RonnyPfannschmidt/followers","following_url":"https://api.github.com/users/RonnyPfannschmidt/following{/other_user}","gists_url":"https://api.github.com/users/RonnyPfannschmidt/gists{/gist_id}","starred_url":"https://api.github.com/users/RonnyPfannschmidt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RonnyPfannschmidt/subscriptions","organizations_url":"https://api.github.com/users/RonnyPfannschmidt/orgs","repos_url":"https://api.github.com/users/RonnyPfannschmidt/repos","events_url":"https://api.github.com/users/RonnyPfannschmidt/events{/privacy}","received_events_url":"https://api.github.com/users/RonnyPfannschmidt/received_events","type":"User","site_admin":false},"created_at":"2015-01-16T20:03:11Z","updated_at":"2015-01-16T20:03:11Z","body":"on a sidenote, json is supposed to be None on valid requests that are not json\r\n\r\nits wrong not to fail if a request claims to be json but isnt\r\n"}}