Skip to content

JiuwenSwarm is an intelligent AI Agent built on openJiuwen. It extends the powerful capabilities of large language models directly to your fingertips through various communication apps you use daily.

Python

fix: 智能体选项卡显示了隐藏文件夹

openJiuwen-bot64a03cc36b79
diff --git a/jiuwenclaw/agentserver/skill_manager.py b/jiuwenclaw/agentserver/skill_manager.py
index 44a19ee0e0..6e4ea815fb 100644
--- a/jiuwenclaw/agentserver/skill_manager.py
+++ b/jiuwenclaw/agentserver/skill_manager.py
@@ -2520,7 +2520,10 @@ class SkillManager:
folder_data: dict[str, list[dict[str, str | bool]]] = {}
seen_paths: dict[str, set[str]] = {}
for entry in sorted(agent_root.rglob("*")):
- if not entry.is_file():
+ if not entry.is_file() or entry.name.startswith("."):
+ continue
+ # Skip files in hidden directories (e.g., .agent_history)
+ if any(part.startswith(".") for part in entry.relative_to(agent_root).parts):
continue
relative_folder_path = entry.parent.relative_to(agent_root.parent).as_posix()
folder_key = root_folder_key if relative_folder_path == "." else relative_folder_path
diff --git a/jiuwenclaw/app_web.py b/jiuwenclaw/app_web.py
index ae942477c1..7248cb3a1c 100644
--- a/jiuwenclaw/app_web.py
+++ b/jiuwenclaw/app_web.py
@@ -89,6 +89,9 @@ def _generate_agent_data(project_root: Path) -> None:
for entry in sorted(workspace_root.rglob("*")):
if not entry.is_file() or entry.name.startswith("."):
continue
+ # Skip files in hidden directories (e.g., .agent_history)
+ if any(part.startswith(".") for part in entry.relative_to(workspace_root).parts):
+ continue
relative_folder_path = entry.parent.relative_to(agent_root).as_posix()
folder_key = root_folder_key if relative_folder_path == "." else relative_folder_path