-
Notifications
You must be signed in to change notification settings - Fork 175
gen-markdown-datadict reads every element on reloads - O(n) #3637
Open
Description
Describe the bug
MarkdownDataDictGen._generate_class_diagram() instantiates a new ERDiagramGenerator (and therefore a new SchemaView) for every class. On any moderately large schema the generator effectively hangs.
No caching / no reuse.
Version of LinkML you are using
1.11.1
Reproducer
mkdir -p /tmp/mdd && cd /tmp/mdd uv run python - << 'PY' print('id: https://example.org/big') print('name: big') print('prefixes:') print(' linkml: https://w3id.org/linkml/') print('imports:') print(' - linkml:types') print('default_range: string') print('classes:') print(' Base:') print(' attributes:') print(' id:') print(' identifier: true') for i in range(500): print(f' Klass{i}:') print(f' is_a: Base') print(f' attributes:') print(f' ref:') print(f' range: Klass{(i+1) % 500}') PY > schema.yaml time uv run gen-markdown-datadict schema.yaml -d out # many minutes
Metadata
Metadata
Assignees
Labels
Type
Fields
Give feedbackNo fields configured for issues without a type.