-
Notifications
You must be signed in to change notification settings - Fork 1
Closed
Labels
bugSomething isn't workingSomething isn't workinggithub_actionsPull requests that update GitHub Actions codePull requests that update GitHub Actions code
Description
The generate-pages action fails when provided a source YAML with an empty field.
This is specifically a bug in browser_export.py.
See https://github.com/monarch-initiative/dismech/actions/runs/20855636245/job/59921394677
Run just gen-browser-data
uv run python -c "from pathlib import Path; from dismech.export import BrowserExporter; BrowserExporter().export_to_js(sorted(Path('kb/disorders').glob('*.yaml')), Path('app/data.js'))"
Traceback (most recent call last):
File "<string>", line 1, in <module>
from pathlib import Path; from dismech.export import BrowserExporter; BrowserExporter().export_to_js(sorted(Path('kb/disorders').glob('*.yaml')), Path('app/data.js'))
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/runner/work/dismech/dismech/src/dismech/export/browser_export.py", line 151, in export_to_js
record = self.extract_disorder(disorder, file_path.name)
File "/home/runner/work/dismech/dismech/src/dismech/export/browser_export.py", line 85, in extract_disorder
genes = [g.get("name", "") for g in disorder.get("genetic", []) if g.get("name")]
~~~~~~~~~~~~^^^^^^^^^^^^^^^
TypeError: 'NoneType' object is not iterable
error: Recipe `gen-browser-data` failed on line 262 with exit code 1Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workinggithub_actionsPull requests that update GitHub Actions codePull requests that update GitHub Actions code