fix: add agent context check to skill visibility validation

This commit is contained in:
2026-06-04 14:19:38 -06:00
parent c13d66e9c8
commit 2474748be6
+5
View File
@@ -205,7 +205,12 @@ impl GraphValidator {
.and_then(|c| c.app_config.visible_skills.as_deref());
let skill_exists = self.skill_exists;
let has_agent_ctx = self.agent_ctx.is_some();
let check_visibility = |name: &str| -> Option<String> {
if !has_agent_ctx {
return None;
}
match visible_skills {
Some(list) if !list.iter().any(|s| s == name) => Some(format!(
"'{name}' is not in the global 'visible_skills' allow-list"