{"action":"created","issue":{"url":"https://api.github.com/repos/NancyFx/Nancy/issues/1638","labels_url":"https://api.github.com/repos/NancyFx/Nancy/issues/1638/labels{/name}","comments_url":"https://api.github.com/repos/NancyFx/Nancy/issues/1638/comments","events_url":"https://api.github.com/repos/NancyFx/Nancy/issues/1638/events","html_url":"https://github.com/NancyFx/Nancy/issues/1638","id":39127828,"number":1638,"title":"Inconsistent behavior of OnError pipeline","user":{"login":"sloncho","id":982079,"avatar_url":"https://avatars.githubusercontent.com/u/982079?v=3","gravatar_id":"","url":"https://api.github.com/users/sloncho","html_url":"https://github.com/sloncho","followers_url":"https://api.github.com/users/sloncho/followers","following_url":"https://api.github.com/users/sloncho/following{/other_user}","gists_url":"https://api.github.com/users/sloncho/gists{/gist_id}","starred_url":"https://api.github.com/users/sloncho/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sloncho/subscriptions","organizations_url":"https://api.github.com/users/sloncho/orgs","repos_url":"https://api.github.com/users/sloncho/repos","events_url":"https://api.github.com/users/sloncho/events{/privacy}","received_events_url":"https://api.github.com/users/sloncho/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":7,"created_at":"2014-07-30T19:26:20Z","updated_at":"2015-10-20T19:45:34Z","closed_at":null,"body":"According to the wiki: \"If only one exception is wrapped, then Nancy will unwrap that exception and hand it to the OnError pipeline.\"\r\n\r\nThe above statement is right, if a hook is attached to the application piepelines.\r\n\r\nBut if an error handler is attached to the pipelines in the module, it gets the wrapped AggregationException instead.\r\n\r\nSee [test, demonstrating the issue](https://gist.github.com/sloncho/f43e16f597548678b787)."},"comment":{"url":"https://api.github.com/repos/NancyFx/Nancy/issues/comments/149680723","html_url":"https://github.com/NancyFx/Nancy/issues/1638#issuecomment-149680723","issue_url":"https://api.github.com/repos/NancyFx/Nancy/issues/1638","id":149680723,"user":{"login":"sloncho","id":982079,"avatar_url":"https://avatars.githubusercontent.com/u/982079?v=3","gravatar_id":"","url":"https://api.github.com/users/sloncho","html_url":"https://github.com/sloncho","followers_url":"https://api.github.com/users/sloncho/followers","following_url":"https://api.github.com/users/sloncho/following{/other_user}","gists_url":"https://api.github.com/users/sloncho/gists{/gist_id}","starred_url":"https://api.github.com/users/sloncho/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sloncho/subscriptions","organizations_url":"https://api.github.com/users/sloncho/orgs","repos_url":"https://api.github.com/users/sloncho/repos","events_url":"https://api.github.com/users/sloncho/events{/privacy}","received_events_url":"https://api.github.com/users/sloncho/received_events","type":"User","site_admin":false},"created_at":"2015-10-20T19:45:34Z","updated_at":"2015-10-20T19:45:34Z","body":"Yes, my test passes with the latest code, as well as it does not unwrap inner exceptions."}}