Skip to content

Commit 27d6a19

Browse files
Use PEP 604 unions in docs
1 parent 15c21ad commit 27d6a19

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

docs/conf.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,9 @@
6060
*[p.stem for p in (HERE / "extensions").glob("*.py")],
6161
]
6262

63+
# Prefer PEP 604 union syntax (X | Y) to avoid unresolved typing.Union references.
64+
always_use_bars_union = True
65+
6366
# Enable math notation in mystnb
6467
myst_enable_extensions = [
6568
"amsmath",
@@ -112,7 +115,6 @@ def filter(self, record: pylogging.LogRecord) -> bool:
112115

113116
nitpick_ignore = [
114117
("py:class", "sgkit.display.GenotypeDisplay"),
115-
("py:data", "typing.Union"),
116118
]
117119

118120

0 commit comments

Comments
 (0)