{"action":"created","issue":{"url":"https://api.github.com/repos/awslabs/chalice/issues/50","repository_url":"https://api.github.com/repos/awslabs/chalice","labels_url":"https://api.github.com/repos/awslabs/chalice/issues/50/labels{/name}","comments_url":"https://api.github.com/repos/awslabs/chalice/issues/50/comments","events_url":"https://api.github.com/repos/awslabs/chalice/issues/50/events","html_url":"https://github.com/awslabs/chalice/issues/50","id":165695694,"number":50,"title":"ChaliceViewError Should Print Real Error","user":{"login":"woodlandh","id":10188252,"avatar_url":"https://avatars.githubusercontent.com/u/10188252?v=3","gravatar_id":"","url":"https://api.github.com/users/woodlandh","html_url":"https://github.com/woodlandh","followers_url":"https://api.github.com/users/woodlandh/followers","following_url":"https://api.github.com/users/woodlandh/following{/other_user}","gists_url":"https://api.github.com/users/woodlandh/gists{/gist_id}","starred_url":"https://api.github.com/users/woodlandh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/woodlandh/subscriptions","organizations_url":"https://api.github.com/users/woodlandh/orgs","repos_url":"https://api.github.com/users/woodlandh/repos","events_url":"https://api.github.com/users/woodlandh/events{/privacy}","received_events_url":"https://api.github.com/users/woodlandh/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-07-15T01:55:39Z","updated_at":"2016-07-22T13:13:52Z","closed_at":null,"body":"**tl;dr** ChaliceViewError should print the underlying error message instead of hiding it (I think?)\r\n\r\n[heavily edited]\r\n\r\nBy default, ChaliceViewError does not raise the underlying exception, it only prints \"An internal server error occurred.\"\r\nWhen app.debug = True, ChaliceViewError instead raises the underlying exception.\r\n\r\nI think both of these features should be enabled at the same time. ChaliceViewError should print the real message (so that it is logged in CloudWatch) and then return a nicely-wrapped ChaliceViewError to the client. This way the developer can get errors logged without worrying about 'null' returns on bad requests.\r\n\r\nI've had to do this to gain this functionality:\r\n`\r\n    except Exception as e:\r\n        print(e)\r\n        raise e\r\n`\r\n\r\nAnd still every single error just gets raised as\r\n\r\n`\r\nTraceback (most recent call last):\r\n  File \"/var/task/chalice/__init__.py\", line 148, in __call__\r\n    raise e\r\n`\r\nWhich isn't helpful."},"comment":{"url":"https://api.github.com/repos/awslabs/chalice/issues/comments/234540223","html_url":"https://github.com/awslabs/chalice/issues/50#issuecomment-234540223","issue_url":"https://api.github.com/repos/awslabs/chalice/issues/50","id":234540223,"user":{"login":"jamesls","id":368057,"avatar_url":"https://avatars.githubusercontent.com/u/368057?v=3","gravatar_id":"","url":"https://api.github.com/users/jamesls","html_url":"https://github.com/jamesls","followers_url":"https://api.github.com/users/jamesls/followers","following_url":"https://api.github.com/users/jamesls/following{/other_user}","gists_url":"https://api.github.com/users/jamesls/gists{/gist_id}","starred_url":"https://api.github.com/users/jamesls/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jamesls/subscriptions","organizations_url":"https://api.github.com/users/jamesls/orgs","repos_url":"https://api.github.com/users/jamesls/repos","events_url":"https://api.github.com/users/jamesls/events{/privacy}","received_events_url":"https://api.github.com/users/jamesls/received_events","type":"User","site_admin":false},"created_at":"2016-07-22T13:13:52Z","updated_at":"2016-07-22T13:13:52Z","body":"Your suggestion of printing/logging the exception on the case of error I think makes a lot of sense.\r\n\r\n"}}
{"actor":{"display_login":"jamesls"}}