Skip to content

Commit 46ca26e

Browse files
Make fixture-110 missing-root failure actionable
PR #181 review: _run_fixture_110_case fetched the invocation root span with next() and no default, so a missing root failed with a bare StopIteration. Match _run_fixture_038_case: next((...), None) plus an explicit assert that reports the span names found.
1 parent 418fec4 commit 46ca26e

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

tests/conformance/test_observability.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1979,7 +1979,8 @@ async def _run_fixture_110_case(case: Mapping[str, Any]) -> None:
19791979

19801980
spans = exporter.get_finished_spans()
19811981
expected_tree = cast("list[dict[str, Any]]", case["expected"]["span_tree"])
1982-
inv_root = next(s for s in spans if s.name == "openarmature.invocation" and s.parent is None)
1982+
inv_root = next((s for s in spans if s.name == "openarmature.invocation" and s.parent is None), None)
1983+
assert inv_root is not None, f"invocation root span missing; got {[s.name for s in spans]}"
19831984
_assert_span_tree_matches(spans, [inv_root], expected_tree)
19841985

19851986
# ---- when-skipped branches emit NO span. The span_tree match is

0 commit comments

Comments
 (0)