Skip to content

Commit 2fe555a

Browse files
committed
fix: Handle missing conf.py file in documentation generation
- Add existence check for conf.py before attempting to read it - Skip Sphinx configuration update if conf.py doesn't exist - Fixes multi-format document generation CI failure - Prevents FileNotFoundError when conf.py is missing This resolves the CI error: '[Errno 2] No such file or directory: .../doc/codeDocs/conf.py'
1 parent 45bb70f commit 2fe555a

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

scripts/generate-docs.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -377,6 +377,11 @@ def update_sphinx_config(self):
377377

378378
conf_file = self.output_dir / "conf.py"
379379

380+
# Check if config file exists
381+
if not conf_file.exists():
382+
print(f"⚠️ Configuration file {conf_file} not found, skipping Sphinx config update...")
383+
return
384+
380385
# Read existing config
381386
with open(conf_file) as f:
382387
config_content = f.read()

0 commit comments

Comments
 (0)