fix: resolve clippy lint warnings

- Remove unused import AsyncBufReadExt in compatible.rs
- Remove unused mut keywords from response and tx
- Remove unused variable 'name'
- Prefix unused parameters with _ in traits.rs

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
argenis de la rosa 2026-02-17 05:15:59 -05:00
parent 4070131bb8
commit 1fc5ecc4ff
2 changed files with 5 additions and 9 deletions

View file

@ -277,15 +277,11 @@ fn parse_sse_line(line: &str) -> StreamResult<Option<String>> {
/// Convert SSE byte stream to text chunks. /// Convert SSE byte stream to text chunks.
async fn sse_bytes_to_chunks( async fn sse_bytes_to_chunks(
mut response: reqwest::Response, response: reqwest::Response,
count_tokens: bool, count_tokens: bool,
) -> stream::BoxStream<'static, StreamResult<StreamChunk>> { ) -> stream::BoxStream<'static, StreamResult<StreamChunk>> {
use tokio::io::AsyncBufReadExt;
let name = "stream".to_string();
// Create a channel to send chunks // Create a channel to send chunks
let (mut tx, rx) = tokio::sync::mpsc::channel::<StreamResult<StreamChunk>>(100); let (tx, rx) = tokio::sync::mpsc::channel::<StreamResult<StreamChunk>>(100);
tokio::spawn(async move { tokio::spawn(async move {
// Buffer for incomplete lines // Buffer for incomplete lines

View file

@ -308,9 +308,9 @@ pub trait Provider: Send + Sync {
fn stream_chat_with_history( fn stream_chat_with_history(
&self, &self,
messages: &[ChatMessage], messages: &[ChatMessage],
model: &str, _model: &str,
temperature: f64, _temperature: f64,
options: StreamOptions, _options: StreamOptions,
) -> stream::BoxStream<'static, StreamResult<StreamChunk>> { ) -> stream::BoxStream<'static, StreamResult<StreamChunk>> {
let system = messages let system = messages
.iter() .iter()