Skip to content

Commit 46c2187

Browse files
authored
Bump to rust 1.83.0 (#7167)
1 parent 7af4c36 commit 46c2187

File tree

8 files changed

+14
-15
lines changed

8 files changed

+14
-15
lines changed

.github/workflows/lint-rust.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727
- uses: dtolnay/rust-toolchain@stable
2828
if: steps.changed-files.outputs.any_changed == 'true'
2929
with:
30-
toolchain: "1.81.0"
30+
toolchain: "1.83.0"
3131
components: clippy, rustfmt
3232
- name: Set Environment
3333
if: steps.changed-files.outputs.any_changed == 'true'

rustv1/cross_service/photo_asset_management/src/chunked_uploader.rs

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
22
// SPDX-License-Identifier: Apache-2.0
3-
use std::io::Read;
4-
53
use anyhow::anyhow;
64
use aws_sdk_dynamodb::primitives::DateTime;
75
use aws_sdk_s3::{operation::get_object::GetObjectOutput, types::CompletedPart};
86
use aws_smithy_types_convert::date_time::DateTimeExt;
97
use chrono::NaiveDateTime;
108
use pipe::{pipe, PipeReader, PipeWriter};
9+
use std::io::Read;
1110
use streaming_zip::{Archive, CompressionMode};
1211
use uuid::Uuid;
1312

@@ -37,7 +36,7 @@ pub struct ZipUpload<'a> {
3736
s3_client: &'a aws_sdk_s3::Client,
3837
}
3938

40-
impl<'a> std::fmt::Debug for ZipUpload<'a> {
39+
impl std::fmt::Debug for ZipUpload<'_> {
4140
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
4241
f.debug_struct("ZipUpload")
4342
.field("key", &self.key)
@@ -117,9 +116,9 @@ impl<'a> ZipUploadBuilder<'a> {
117116
}
118117
}
119118

120-
impl<'a> ZipUpload<'a> {
119+
impl ZipUpload<'_> {
121120
// Start a builder for the ZipUpload.
122-
pub fn builder(common: &'a Common) -> ZipUploadBuilder {
121+
pub fn builder(common: &Common) -> ZipUploadBuilder {
123122
ZipUploadBuilder {
124123
key: None,
125124
bucket: None,

rustv1/cross_service/rest_ses/src/client.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ impl AsRef<str> for Email {
9696
}
9797
}
9898

99-
impl<'a> From<Email> for Address<'a> {
99+
impl From<Email> for Address<'_> {
100100
fn from(email: Email) -> Self {
101101
email.0.into()
102102
}

rustv1/cross_service/rest_ses/src/work_item/work_item_archived.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ impl<'de> Deserialize<'de> for WorkItemArchived {
104104
/// The RDS table encodes status as 1 and 0.
105105
/// This serde visit handles those disparate cases, using the try_from impls.
106106
struct Visitor;
107-
impl<'de> de::Visitor<'de> for Visitor {
107+
impl de::Visitor<'_> for Visitor {
108108
type Value = WorkItemArchived;
109109

110110
fn visit_u64<E>(self, value: u64) -> Result<Self::Value, E>
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# This should be kept in sync with https://github.com/awslabs/aws-sdk-rust#supported-rust-versions-msrv
22
[toolchain]
3-
channel = "1.81.0"
3+
channel = "1.83.0"

rustv1/examples/bedrock-runtime/src/bin/tool-use.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
22
// SPDX-License-Identifier: Apache-2.0
33

4+
//! This demo illustrates a tool use scenario using Amazon Bedrock's Converse API and a weather tool.
5+
//! The script interacts with a foundation model on Amazon Bedrock to provide weather information based on user
6+
//! input. It uses the Open-Meteo API (https://open-meteo.com) to retrieve current weather data for a given location.
7+
48
// snippet-start:[rust.bedrock-runtime.Converse_AnthropicClaude.tool-use.supporting]
59
use std::{collections::HashMap, io::stdin};
610

@@ -19,10 +23,6 @@ use aws_smithy_runtime_api::http::Response;
1923
use aws_smithy_types::Document;
2024
use tracing::debug;
2125

22-
/// This demo illustrates a tool use scenario using Amazon Bedrock's Converse API and a weather tool.
23-
/// The script interacts with a foundation model on Amazon Bedrock to provide weather information based on user
24-
/// input. It uses the Open-Meteo API (https://open-meteo.com) to retrieve current weather data for a given location.
25-
2626
// Set the model ID, e.g., Claude 3 Haiku.
2727
const MODEL_ID: &str = "anthropic.claude-3-haiku-20240307-v1:0";
2828
const CLAUDE_REGION: &str = "us-east-1";
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# This should be kept in sync with https://github.com/awslabs/aws-sdk-rust#supported-rust-versions-msrv
22
[toolchain]
3-
channel = "1.81.0"
3+
channel = "1.83.0"

rustv1/examples/s3/src/bin/select-object-content.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ struct Opt {
2525
bucket: String,
2626

2727
/// The object key to scan. This example expects the object to be an uncompressed CSV file with:
28-
28+
///
2929
/// Name,PhoneNumber,City,Occupation
3030
/// Person1,(nnn) nnn-nnnn,City1,Occupation1,Comment
3131
/// ...

0 commit comments

Comments
 (0)