fix: recursive indexing and normalization in create_categories.py & workflow_db.py (fixes #82)

fix: recursive indexing and normalization in create_categories.py & workflow_db.py (fixes #82)
This commit is contained in:
Praveen Mudalgeri
2025-08-12 10:34:22 +05:30
parent e2fa5a7505
commit 4c61958fbc
2 changed files with 25 additions and 19 deletions

View File

@@ -434,10 +434,9 @@ class WorkflowDatabase:
if not os.path.exists(self.workflows_dir):
print(f"Warning: Workflows directory '{self.workflows_dir}' not found.")
return {'processed': 0, 'skipped': 0, 'errors': 0}
workflows_path = Path(self.workflows_dir)
json_files = list(workflows_path.rglob("*.json"))
# json_files = glob.glob(os.path.join(self.workflows_dir, "*.json"), recursive=True)
json_files = [str(p) for p in workflows_path.rglob("*.json")]
if not json_files:
print(f"Warning: No JSON files found in '{self.workflows_dir}' directory.")