(
&self,
hook_type: HookType,
raw_json: Value,
)
| 209 | } |
| 210 | |
| 211 | fn parse_value<T: for<'de> Deserialize<'de>>( |
| 212 | &self, |
| 213 | hook_type: HookType, |
| 214 | raw_json: Value, |
| 215 | ) -> AgentResult<T> { |
| 216 | serde_json::from_value(raw_json).map_err(|e| AgentError::HookParseFailed { |
| 217 | agent: self.name().to_string(), |
| 218 | hook_type: hook_type.as_str().to_string(), |
| 219 | reason: e.to_string(), |
| 220 | }) |
| 221 | } |
| 222 | } |
| 223 | |
| 224 | impl Default for CodexHook { |
no test coverage detected