Parse todo filename to extract workspace_id and agent_id
(filename: &str)
| 471 | |
| 472 | /// Parse todo filename to extract workspace_id and agent_id |
| 473 | fn parse_todo_filename(filename: &str) -> (String, String) { |
| 474 | let name = filename.strip_suffix(".json").unwrap_or(filename); |
| 475 | |
| 476 | if let Some(idx) = name.find("-agent-") { |
| 477 | let workspace_id = name[..idx].to_string(); |
| 478 | let agent_id = name[idx + 7..].to_string(); |
| 479 | (workspace_id, agent_id) |
| 480 | } else { |
| 481 | (name.to_string(), "unknown".to_string()) |
| 482 | } |
| 483 | } |
| 484 | |
| 485 | /// Convert serde_json Value to GlueSQL Value |
| 486 | fn json_value_to_glue_value(value: &JsonValue) -> Value { |
no outgoing calls