(cls, values: dict[str, Any])
| 1867 | |
| 1868 | @root_validator(pre=True) |
| 1869 | def values_are_not_string(cls, values: dict[str, Any]) -> dict[str, Any]: |
| 1870 | if any(isinstance(x, str) for x in values.values()): |
| 1871 | raise ValueError('values cannot be a string') |
| 1872 | return values |
| 1873 | |
| 1874 | m = Model(current=100, max_value=200) |
| 1875 | with pytest.raises(ValidationError) as exc_info: |