style: Apply cargo fix for unused variables
This commit is contained in:
1 parent
9f00d8298f
commit
7c9e901c12
2 files changed
+7
-7
No files matched your search
@@ -165,7 +165,7 @@ impl McpTool for CreateEntitiesHandler {
|
||||
state.modify_graph(|g| {
|
||||
for entity_input in req.entities {
|
||||
if !entity_input.name.is_empty() {
|
||||
let mut entity = crate::models::Entity {
|
||||
let entity = crate::models::Entity {
|
||||
name: entity_input.name.clone(),
|
||||
entity_type: crate::models::normalize_entity_type(&entity_input.entity_type),
|
||||
observations: entity_input.observations,
|
||||
@@ -264,7 +264,7 @@ impl McpTool for CreateRelationsHandler {
|
||||
}
|
||||
for relation_input in req.relations {
|
||||
if !relation_input.from.is_empty() && !relation_input.to.is_empty() {
|
||||
let mut relation = crate::models::Relation {
|
||||
let relation = crate::models::Relation {
|
||||
from: relation_input.from,
|
||||
to: relation_input.to,
|
||||
relation_type: crate::models::normalize_relation_type(&relation_input.relation_type),
|
||||
|
||||
@@ -609,7 +609,7 @@ impl McpTool for TechDebtHandler {
|
||||
async fn execute(&self, args: Value, state: Arc<MemoryState>) -> crate::error::Result<String> {
|
||||
let req: TechDebtTool = serde_json::from_value(args).map_err(|e| e.to_string())?;
|
||||
match req {
|
||||
TechDebtTool::Log { description, title, ideal_solution, git_commit, git_branch, symbol_references, line_range, namespace, severity, repo_name, file_path, workaround, effort_estimate } => {
|
||||
TechDebtTool::Log { description, title: _, ideal_solution, git_commit, git_branch, symbol_references: _, line_range, namespace, severity, repo_name, file_path, workaround, effort_estimate } => {
|
||||
let ns = namespace.clone().unwrap_or_else(crate::models::default_namespace);
|
||||
let desc = description;
|
||||
let ideal = ideal_solution.unwrap_or_default();
|
||||
@@ -1203,7 +1203,7 @@ impl McpTool for ManageCheckpointHandler {
|
||||
|
||||
Ok(format!("Checkpoint '{}' created successfully.", name))
|
||||
}
|
||||
ManageCheckpointTool::Restore { name_or_id, namespace } => {
|
||||
ManageCheckpointTool::Restore { name_or_id, namespace: _ } => {
|
||||
let name = name_or_id.ok_or_else(|| crate::error::AppError::Internal("name_or_id is required".to_string()))?;
|
||||
let target_dir = state.base_dir.join("checkpoints").join(&name);
|
||||
|
||||
@@ -1245,7 +1245,7 @@ impl McpTool for ManageCheckpointHandler {
|
||||
|
||||
Ok(format!("Checkpoint '{}' restored successfully.", name))
|
||||
}
|
||||
ManageCheckpointTool::List { namespace } => {
|
||||
ManageCheckpointTool::List { namespace: _ } => {
|
||||
let mut list = Vec::new();
|
||||
let checkpoints_dir = state.base_dir.join("checkpoints");
|
||||
if let Ok(entries) = std::fs::read_dir(&checkpoints_dir) {
|
||||
@@ -1263,7 +1263,7 @@ impl McpTool for ManageCheckpointHandler {
|
||||
}
|
||||
Ok(serde_yaml::to_string(&list)?)
|
||||
}
|
||||
ManageCheckpointTool::Delete { name_or_id, namespace } => {
|
||||
ManageCheckpointTool::Delete { name_or_id, namespace: _ } => {
|
||||
let name = name_or_id.ok_or_else(|| crate::error::AppError::Internal("name_or_id is required".to_string()))?;
|
||||
let target_dir = state.base_dir.join("checkpoints").join(&name);
|
||||
if target_dir.exists() {
|
||||
@@ -1483,7 +1483,7 @@ impl McpTool for HypothesesHandler {
|
||||
|
||||
Ok(format!("Hypothesis '{}' logged successfully.", hyp_id))
|
||||
}
|
||||
HypothesesTool::Query { query, task_id, status } => {
|
||||
HypothesesTool::Query { query, task_id, status: _ } => {
|
||||
let hypotheses = state.code.hypotheses.read_with(|h| h.clone());
|
||||
let filtered: Vec<_> = hypotheses
|
||||
.into_iter()
|
||||
|
||||
Reference in new issue
Block a user