Commit f586036
committed
fix: migrate GeometryValidatorMixin to Pydantic V2 field_validator
The V1-style @validator decorator is deprecated in Pydantic 2.x and
scheduled for removal in V3. Migrates GeometryValidatorMixin's geometry
validator to the V2 @field_validator API, adding the explicit
@classmethod that V2 requires (V1 handled this implicitly).
Validator logic is unchanged. Verified: no PydanticDeprecatedSince20
warning fires for this validator anymore, and the existing test suite
still passes (5 passed).
Part of incremental migration for #256 - other validators/Field(example=)
usages in this file still need converting in follow-up PRs.
Signed-off-by: Brian Bergstrom <dulcetberg@gmail.com>1 parent e69a6e3 commit f586036
1 file changed
Lines changed: 3 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
| 27 | + | |
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
| |||
120 | 120 | | |
121 | 121 | | |
122 | 122 | | |
123 | | - | |
| 123 | + | |
| 124 | + | |
124 | 125 | | |
125 | 126 | | |
126 | 127 | | |
| |||
0 commit comments