{"action":"created","issue":{"url":"https://api.github.com/repos/yahoo/fetchr/issues/130","labels_url":"https://api.github.com/repos/yahoo/fetchr/issues/130/labels{/name}","comments_url":"https://api.github.com/repos/yahoo/fetchr/issues/130/comments","events_url":"https://api.github.com/repos/yahoo/fetchr/issues/130/events","html_url":"https://github.com/yahoo/fetchr/pull/130","id":115254828,"number":130,"title":"Allow error response to have meta-data","user":{"login":"banghui","id":2006681,"avatar_url":"https://avatars.githubusercontent.com/u/2006681?v=3","gravatar_id":"","url":"https://api.github.com/users/banghui","html_url":"https://github.com/banghui","followers_url":"https://api.github.com/users/banghui/followers","following_url":"https://api.github.com/users/banghui/following{/other_user}","gists_url":"https://api.github.com/users/banghui/gists{/gist_id}","starred_url":"https://api.github.com/users/banghui/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/banghui/subscriptions","organizations_url":"https://api.github.com/users/banghui/orgs","repos_url":"https://api.github.com/users/banghui/repos","events_url":"https://api.github.com/users/banghui/events{/privacy}","received_events_url":"https://api.github.com/users/banghui/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/yahoo/fetchr/labels/ready","name":"ready","color":"ededed"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-11-05T10:32:43Z","updated_at":"2015-12-04T04:34:45Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/yahoo/fetchr/pulls/130","html_url":"https://github.com/yahoo/fetchr/pull/130","diff_url":"https://github.com/yahoo/fetchr/pull/130.diff","patch_url":"https://github.com/yahoo/fetchr/pull/130.patch"},"body":"Up till version 0.5.17 erroneous responses were able to carry meta-data. Is it possible to reinstate this capability in new versions of fetchr? Or is there a reason for disallowing meta-data from being passed on when the service fails? Thanks!"},"comment":{"url":"https://api.github.com/repos/yahoo/fetchr/issues/comments/161872956","html_url":"https://github.com/yahoo/fetchr/pull/130#issuecomment-161872956","issue_url":"https://api.github.com/repos/yahoo/fetchr/issues/130","id":161872956,"user":{"login":"banghui","id":2006681,"avatar_url":"https://avatars.githubusercontent.com/u/2006681?v=3","gravatar_id":"","url":"https://api.github.com/users/banghui","html_url":"https://github.com/banghui","followers_url":"https://api.github.com/users/banghui/followers","following_url":"https://api.github.com/users/banghui/following{/other_user}","gists_url":"https://api.github.com/users/banghui/gists{/gist_id}","starred_url":"https://api.github.com/users/banghui/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/banghui/subscriptions","organizations_url":"https://api.github.com/users/banghui/orgs","repos_url":"https://api.github.com/users/banghui/repos","events_url":"https://api.github.com/users/banghui/events{/privacy}","received_events_url":"https://api.github.com/users/banghui/received_events","type":"User","site_admin":false},"created_at":"2015-12-04T04:34:45Z","updated_at":"2015-12-04T04:34:45Z","body":"Sorry I forgot about this, thanks for the ping @redonkulus. \r\n@Vijar You are right. In `0.5.17` meta was never supported. We were, however, able to set  __headers__ for error responses then, but not anymore since the `0.5.18` release. I am trying to enable the setting of headers for error responses in this PR (not support meta in the error response payload, my bad!!). Thanks for clarifying!\r\n\r\nIn `0.5.17` headers were being set using the `meta` object provided by the [callbacks](https://github.com/yahoo/fetchr/blob/v0.5.17/libs/fetcher.js#L261-L265). In `0.5.17` headers were set using the [Request object's](https://github.com/yahoo/fetchr/blob/v0.5.18/libs/fetcher.js#L304-L314) `serviceMeta` property. The shift to using promises in `0.5.18` [omitted the setting of the Request object's serviceMeta property on errors](https://github.com/yahoo/fetchr/blob/v0.5.18/libs/fetcher.js#L141-L156), hence the inability to set headers for erroneous responses.\r\n\r\nLet me know how I should proceed, thanks"}}