Load metadata from documentation directory. Args: docs_dir: Documentation directory path Returns: Metadata dictionary or None if not found
(self, docs_dir: Path)
| 60 | """ |
| 61 | Load metadata from documentation directory. |
| 62 | |
| 63 | Args: |
| 64 | docs_dir: Documentation directory path |
| 65 | |
| 66 | Returns: |
| 67 | Metadata dictionary or None if not found |
| 68 | """ |
| 69 | metadata_path = docs_dir / "metadata.json" |
| 70 | if not metadata_path.exists(): |
| 71 | return None |
| 72 | |
| 73 | try: |
| 74 | content = safe_read(metadata_path) |
| 75 | return json.loads(content) |
| 76 | except Exception: |
| 77 | # Non-critical, return None |
| 78 | return None |
| 79 | |
| 80 | def generate( |
| 81 | self, |
| 82 | output_path: Path, |
| 83 | title: str, |
| 84 | module_tree: Optional[Dict[str, Any]] = None, |