pydantic-core icon indicating copy to clipboard operation
pydantic-core copied to clipboard

Core validation logic for pydantic written in rust

Results 181 pydantic-core issues
Sort by recently updated
recently updated
newest added

PyO3 head contains some breaking changes and perf tweaks; I want to get early visibility onto those.

Union serializers do a pretty good job of warning, but we are relatively inconsistent with how we do this across different type serializers in `pydantic-core`. Let's add more warnings for...

refactor

Hello, running the following code to build mysql url will cause a error when password contains a special character `#`. ``` from pydantic import MySQLDsn MySQLDsn.build( scheme="mysql+aiomysql", username="test", password="test#1", host="127.0.0.1",...

See https://github.com/pydantic/pydantic-core/pull/1451#discussion_r1768893269 for more context :).

I'd love to see `ValidationError.from_exception_data()` documented in more detail, with examples. I realize that constructing a `ValidationError` directly is very rarely the "right" thing to do... but I've recently run...

documentation

## Change Summary Improved precision of float `multiple_of` validation and added test cases. - Refine the validation logic for better handling of floating-point rounding errors - Implement a more robust...

ready for review

After a few minor releases (maybe we can do this in `pydantic v2.12`ish), let's remove the tagged union fallback to union serialization and instead just fallback to inference. We'll need...

enhancement

Introduces a `nested` `CoreSchema` variant that reuses the specified model's schema/validator/serializer. As an example, the core schema for the following pydantic models: ```python class A(BaseModel): field3: 'B' class B(BaseModel): field1:...

This disables wrapping/consuming generators while serializing, while calling the fallback function on them. In many cases, we want to implement some custom serialization logic for generators (such as io.IOBase), instead...

## Change Summary We're currently working around [pydantic#8907](https://github.com/pydantic/pydantic/issues/8907) by parsing the pointer out of the `repr()`. To make this workaround slightly better, we'd like to expose the wrapped iterator in...