aboutsummaryrefslogtreecommitdiffstats
path: root/teleterm/src/error.rs
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2019-11-27 13:10:06 -0500
committerJesse Luehrs <doy@tozt.net>2019-11-27 15:17:59 -0500
commit2bb014f580863f28ecbbea68a2b0aeaa815dc8ca (patch)
tree235397a0d50f76fa906697eb1279f10905398cbd /teleterm/src/error.rs
parent0a31f6bcd806eeaf1fcfddbcfbd466db969ed006 (diff)
downloadteleterm-2bb014f580863f28ecbbea68a2b0aeaa815dc8ca.tar.gz
teleterm-2bb014f580863f28ecbbea68a2b0aeaa815dc8ca.zip
better error messages
Diffstat (limited to 'teleterm/src/error.rs')
-rw-r--r--teleterm/src/error.rs20
1 files changed, 19 insertions, 1 deletions
diff --git a/teleterm/src/error.rs b/teleterm/src/error.rs
index f7946dd..d75aea3 100644
--- a/teleterm/src/error.rs
+++ b/teleterm/src/error.rs
@@ -74,7 +74,10 @@ pub enum Error {
#[snafu(display("received EOF from server"))]
EOF,
- #[snafu(display("failed to retrieve access token: {:?}", msg))]
+ #[snafu(display(
+ "failed to retrieve access token from authorization code: {:?}",
+ msg
+ ))]
ExchangeCode {
msg: String,
// XXX RequestTokenError doesn't implement the right traits
@@ -87,6 +90,21 @@ pub enum Error {
},
#[snafu(display(
+ "failed to retrieve access token from refresh token: {:?}",
+ msg
+ ))]
+ ExchangeRefreshToken {
+ msg: String,
+ // XXX RequestTokenError doesn't implement the right traits
+ // source: oauth2::RequestTokenError<
+ // oauth2::reqwest::Error,
+ // oauth2::StandardErrorResponse<
+ // oauth2::basic::BasicErrorResponseType,
+ // >,
+ // >
+ },
+
+ #[snafu(display(
"failed to parse string {:?}: unexpected trailing data",
data
))]