chore(rs): update dependencies (#1494)

### Chores
- Update cargo dependencies
- Remove unused cargo dependencies
- Fix clippy warnings
- Update Dockerfile (package.json requires node 22)
- Let Dependabot update bun, cargo, devcontainers, docker,
github-actions, npm (nix still not supported)

### TODO
- Upgrade dependencies with breaking changes

```shell
$ cargo update --verbose
   Unchanged crossterm v0.28.1 (available: v0.29.0)
   Unchanged schemars v0.8.22 (available: v1.0.4)
```
This commit is contained in:
Rene Leonhardt
2025-07-10 20:08:16 +02:00
committed by GitHub
parent 3a23a86f4b
commit 82b0cebe8b
36 changed files with 673 additions and 615 deletions

View File

@@ -37,7 +37,7 @@ pub struct Prompt {
}
impl Prompt {
pub(crate) fn get_full_instructions(&self, model: &str) -> Cow<str> {
pub(crate) fn get_full_instructions(&self, model: &str) -> Cow<'_, str> {
let mut sections: Vec<&str> = vec![BASE_INSTRUCTIONS];
if let Some(ref user) = self.user_instructions {
sections.push(user);

View File

@@ -1297,7 +1297,7 @@ async fn handle_function_call(
ResponseInputItem::FunctionCallOutput {
call_id,
output: FunctionCallOutputPayload {
content: format!("unsupported call: {}", name),
content: format!("unsupported call: {name}"),
success: None,
},
}
@@ -1489,8 +1489,7 @@ async fn handle_sandbox_error(
call_id,
output: FunctionCallOutputPayload {
content: format!(
"failed in sandbox {:?} with execution error: {error}",
sandbox_type
"failed in sandbox {sandbox_type:?} with execution error: {error}"
),
success: Some(false),
},

View File

@@ -240,8 +240,7 @@ mod tests {
] {
assert!(
!is_safe_to_call_with_exec(&args),
"expected {:?} to be unsafe",
args
"expected {args:?} to be unsafe"
);
}
}

View File

@@ -145,7 +145,7 @@ impl From<Vec<InputItem>> for ResponseInputItem {
.unwrap_or_else(|| "application/octet-stream".to_string());
let encoded = base64::engine::general_purpose::STANDARD.encode(bytes);
Some(ContentItem::InputImage {
image_url: format!("data:{};base64,{}", mime, encoded),
image_url: format!("data:{mime};base64,{encoded}"),
})
}
Err(err) => {