You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"Request object is not clonable. Are you passing a streaming body?".to_string()
87
+
))
88
+
})?;
89
+
new_req.headers_mut().insert(
90
+
reqwest::header::AUTHORIZATION,
91
+
format!("Bearer {}", new_token).parse().unwrap(),
92
+
);
93
+
94
+
response = next.run(new_req, extensions).await?;
95
+
96
+
if response.status() == StatusCode::FORBIDDEN{
97
+
log::error!(
98
+
"Received 403 Forbidden after refreshing the token. This may indicate invalid credentials, insufficient permissions, or a server-side issue. Check the token, request headers, and server configuration."
99
+
);
100
+
}
101
+
}
102
+
103
+
Ok(response)
56
104
}
57
105
}
58
106
@@ -84,17 +132,11 @@ async fn token(
84
132
.unwrap()
85
133
.as_secs();
86
134
87
-
if token.expires_at >= 0 && (token.expires_atasu64) > current_time {
88
-
log::debug!("Using stored bearer token for all requests");
0 commit comments