Skip to content

Conversation

@davidhewitt
Copy link
Contributor

Change Summary

The last value in Extra which changes, now moved to SerializationState.

With this done, I can make a follow-up where Extra becomes a constant value inside SerializationState, which will mean only state needs to get passed around and everything possibly relevant is contained within it.

Related issue number

N/A

Checklist

  • Unit tests for the changes exist
  • Documentation reflects the changes where applicable
  • Pydantic tests pass with this pydantic-core (except for expected changes)
  • My PR is ready to review, please add a comment including the phrase "please review" to assign reviewers

@davidhewitt davidhewitt requested a review from Viicos October 27, 2025 15:19
warnings: self.warnings.clone(),
rec_guard: self.rec_guard.clone(),
config: self.config,
model: self.model.as_ref().map(|m| m.bind(py).clone()),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was this missed from the previous release?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah no I just moved it up a few lines so that this matches the order the fields are defined in the struct.

@davidhewitt davidhewitt enabled auto-merge (squash) October 27, 2025 15:22
@davidhewitt davidhewitt merged commit 3359241 into main Oct 27, 2025
31 checks passed
@davidhewitt davidhewitt deleted the dh/ser-state-check branch October 27, 2025 15:27
@codspeed-hq
Copy link

codspeed-hq bot commented Oct 27, 2025

CodSpeed Performance Report

Merging #1862 will degrade performances by 11.79%

Comparing dh/ser-state-check (b1218c1) with main (423264f)

Summary

❌ 1 regression
✅ 162 untouched

⚠️ Please fix the performance issues or acknowledge them on CodSpeed.

Benchmarks breakdown

Benchmark BASE HEAD Change
test_list_of_strs_json_uncached 339.1 µs 384.4 µs -11.79%

davidhewitt added a commit to pydantic/pydantic that referenced this pull request Nov 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants