pydantic / pydantic-core

Core validation logic for pydantic written in rust
MIT License
1.34k stars 207 forks source link

Fix serialize_as_any with recursive ref #1359

Open nix010 opened 6 days ago

nix010 commented 6 days ago

BaseModel.model_dump[_xxx](serialize_as_any = True) breaks with models with recursive attribute types (not values) https://github.com/pydantic/pydantic/issues/9670

Related issue number

fix https://github.com/pydantic/pydantic/issues/9670

Checklist

codspeed-hq[bot] commented 6 days ago

CodSpeed Performance Report

Merging #1359 will not alter performance

Comparing nix010:fix-serialize-as-any-with-recursive-ref (7b5c8ce) with main (a017bd9)

Summary

✅ 155 untouched benchmarks