with the expected types and are properly defined as Pydantic models. assert hasattr(result, "model_dump"), "ModerationResult should have model_dump method (Pydantic ...
"""Lint: detect `with a() and b():` (boolean op in with-statement context). Using `and`/`or` to combine context managers is almost always a bug: with ctx_a() and ctx ...