From 17822627914c39a3eb95ee2d400dbba3cd9b7110 Mon Sep 17 00:00:00 2001 From: Neil Conway Date: Fri, 7 Aug 2026 20:15:01 -0400 Subject: [PATCH] fix: box aws-config loading future avoid clippy warning In aws-config >= 1.10, the future returned by ConfigLoader::load() is large enough that it triggers the clippy `large_futures` error (as seen in the CI failures for #24163). Fix this by using `Box::pin`. --- datafusion-cli/src/object_storage.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/datafusion-cli/src/object_storage.rs b/datafusion-cli/src/object_storage.rs index e2ba992961c40..5e6337e303f6f 100644 --- a/datafusion-cli/src/object_storage.rs +++ b/datafusion-cli/src/object_storage.rs @@ -180,7 +180,10 @@ struct CredentialsFromConfig { impl CredentialsFromConfig { /// Attempt find AWS S3 credentials via the AWS SDK pub async fn try_new() -> Result { - let config = aws_config::defaults(BehaviorVersion::latest()).load().await; + // Loading the SDK config produces a large future, so box it to avoid + // potentially triggering the `large_futures` clippy lint. + let config = + Box::pin(aws_config::defaults(BehaviorVersion::latest()).load()).await; let region = config.region().map(|r| r.to_string()); let credentials = config