Skip to content

Commit 3361f5d

Browse files
titaiwangmsCopilot
andcommitted
Fix D205 docstring lint on test_raises_on_dtype_contradiction
The new test docstring added in 3b0fa13 tripped the repo's enforced pydocstyle gate (ruff "D" select, google convention): D205 (blank line required after the summary line), D209 (closing quotes on their own line), and the resulting ruff format diff, failing the PR Lint check. Rewrite the docstring as a single-line summary followed by a blank line and a wrapped description. Lint-only change; no test logic or assertions are touched (22 dtype/fold-concat tests still pass). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: titaiwang <titaiwang@microsoft.com>
1 parent 72cee28 commit 3361f5d

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

src/mobius/_passes/_dtype_utils_test.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,11 @@ def test_falls_back_to_const_value_when_declared_missing(self):
3636
assert initializer_dtype(v) == ir.DataType.FLOAT16
3737

3838
def test_raises_on_dtype_contradiction(self):
39-
"""A declared type that contradicts the serialized data is corrupt
40-
metadata and must fail closed rather than silently pick one dtype."""
39+
"""Reject values whose declared dtype contradicts the serialized data.
40+
41+
Such a value is corrupt metadata and must fail closed rather than
42+
silently pick one dtype.
43+
"""
4144
v = _value(ir.DataType.FLOAT, np.ones((2,), np.float16))
4245
with pytest.raises(ValueError) as excinfo:
4346
initializer_dtype(v)

0 commit comments

Comments
 (0)