{"action":"opened","issue":{"url":"https://api.github.com/repos/briansmith/ring/issues/363","repository_url":"https://api.github.com/repos/briansmith/ring","labels_url":"https://api.github.com/repos/briansmith/ring/issues/363/labels{/name}","comments_url":"https://api.github.com/repos/briansmith/ring/issues/363/comments","events_url":"https://api.github.com/repos/briansmith/ring/issues/363/events","html_url":"https://github.com/briansmith/ring/issues/363","id":192449178,"number":363,"title":"Add feature for getting backtraces for `ring::error::Unspecified`","user":{"login":"briansmith","id":16816,"avatar_url":"https://avatars.githubusercontent.com/u/16816?v=3","gravatar_id":"","url":"https://api.github.com/users/briansmith","html_url":"https://github.com/briansmith","followers_url":"https://api.github.com/users/briansmith/followers","following_url":"https://api.github.com/users/briansmith/following{/other_user}","gists_url":"https://api.github.com/users/briansmith/gists{/gist_id}","starred_url":"https://api.github.com/users/briansmith/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/briansmith/subscriptions","organizations_url":"https://api.github.com/users/briansmith/orgs","repos_url":"https://api.github.com/users/briansmith/repos","events_url":"https://api.github.com/users/briansmith/events{/privacy}","received_events_url":"https://api.github.com/users/briansmith/received_events","type":"User","site_admin":false},"labels":[{"id":306920625,"url":"https://api.github.com/repos/briansmith/ring/labels/good-first-bug","name":"good-first-bug","color":"fbca04","default":false},{"id":274468306,"url":"https://api.github.com/repos/briansmith/ring/labels/usability","name":"usability","color":"bfd4f2","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-11-30T01:17:46Z","updated_at":"2016-11-30T01:17:46Z","closed_at":null,"body":"It would be nice, especially when debugging test failures, if we could enable a feature that would let us get the call stack at the time the (most recent?) `ring::error::Unspecified` was constructed.\r\n\r\nSee the article here: http://phildawes.net/blog/2015/06/17/rust-stacktrace/ for ideas.\r\n\r\nPerhaps there would be a feature flag to enable the functionality at build time, which, if set to a non-empty value, would cause a backtrace to be created. This feature flag would then also control whether we depend on the backtrace library or not.\r\n\r\nWhen the feature is enabled, the `ring::error::Unspecified` could contain the stack trace object and expose a way to get it and/or to print it. Then `ring::test` can be modified to print any `ring::error::Unspecified` returned to it. Note that this means that we should avoid any coding patterns that compare one `Result<T, ring::error::Unspecified>` to another using `assert_eq!(Ok(expected), function_call_returning_result(...))`. Instead we should always use `try!()` when calling `Result`-returning functions (in tests)."}}
{"actor":{"display_login":"briansmith"}}