Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix JSON Schema reference collection with "examples" keys #11325

Merged
merged 1 commit into from
Jan 23, 2025

Conversation

Viicos
Copy link
Member

@Viicos Viicos commented Jan 23, 2025

Change Summary

Backport of #11305.

Related issue number

Checklist

  • The pull request title is a good summary of the changes - it will be used in the changelog
  • Unit tests for the changes exist
  • Tests pass on CI
  • Documentation reflects the changes where applicable
  • My PR is ready to review, please add a comment including the phrase "please review" to assign reviewers

Sorry, something went wrong.

@github-actions github-actions bot added the relnotes-fix Used for bugfixes. label Jan 23, 2025
Copy link

Deploying pydantic-docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: 672e369
Status: ✅  Deploy successful!
Preview URL: https://81b33700.pydantic-docs.pages.dev
Branch Preview URL: https://backport-11305.pydantic-docs.pages.dev

View logs

Copy link

codspeed-hq bot commented Jan 23, 2025

CodSpeed Performance Report

Merging #11325 will degrade performances by 29.82%

Comparing backport-11305 (672e369) with main (14d14b0)

🎉 Hooray! pytest-codspeed just leveled up to 2.2.1!

A heads-up, this is a breaking change and it might affect your current performance baseline a bit. But here's the exciting part - it's packed with new, cool features and promises improved result stability 🥳!
Curious about what's new? Visit our releases page to delve into all the awesome details about this new version.

Summary

❌ 35 regressions
✅ 8 untouched benchmarks
⁉️ 2 dropped benchmarks

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

Benchmarks breakdown

Benchmark BASE HEAD Change
⁉️ test_getattr 54.4 µs N/A N/A
⁉️ test_setattr 86.1 µs N/A N/A
test_schema_build 2.9 ms 3.3 ms -13.46%
test_fastapi_startup_perf 200.1 ms 250.6 ms -20.14%
test_fastapi_startup_perf 26.2 ms 30.6 ms -14.44%
test_complex_model_schema_generation 1.8 ms 2.6 ms -29.82%
test_construct_dataclass_schema 1.8 ms 2.2 ms -16.79%
test_lots_of_models_with_lots_of_fields 2.7 s 3.3 s -19.09%
test_model_validators_serializers 906.8 µs 1,033.7 µs -12.27%
test_nested_model_schema_generation 1.1 ms 1.3 ms -11.2%
test_recursive_model_schema_generation 1 ms 1.3 ms -18.94%
test_simple_model_schema_generation 746.6 µs 893.6 µs -16.46%
test_simple_model_schema_lots_of_fields_generation 28.5 ms 38.5 ms -25.83%
test_tagged_union_with_callable_discriminator_schema_generation 1.5 ms 1.9 ms -24.12%
test_tagged_union_with_str_discriminator_schema_generation 1.5 ms 1.8 ms -12.74%
test_deeply_nested_recursive_model_schema_generation 1.3 ms 1.5 ms -13.6%
test_generic_recursive_model_schema_generation 896.9 µs 1,063.6 µs -15.68%
test_nested_recursive_generic_model_schema_generation 1.7 ms 2.2 ms -21.62%
test_nested_recursive_model_schema_generation 1.8 ms 2.2 ms -16.35%
test_recursive_discriminated_union_with_base_model 1.7 ms 2 ms -14%
... ... ... ... ...

ℹ️ Only the first 20 benchmarks are displayed. Go to the app to view all benchmarks.

Copy link
Contributor

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  pydantic
  json_schema.py
Project Total  

This report was generated by python-coverage-comment-action

@Viicos Viicos merged commit f94e842 into v2.10-patches Jan 23, 2025
54 of 55 checks passed
@Viicos Viicos deleted the backport-11305 branch January 23, 2025 15:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
relnotes-fix Used for bugfixes.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant