Skip to content

build(deps-dev): bump datamodel-code-generator from 0.31.2 to 0.88.0 in /sdk/python - #1019

Closed
dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/pip/sdk/python/datamodel-code-generator-0.88.0
Closed

dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/pip/sdk/python/datamodel-code-generator-0.88.0

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Nov 6, 2026

Copy link
Copy Markdown

Bumps datamodel-code-generator from 0.31.2 to 0.88.0.

Release notes

Sourced from datamodel-code-generator's releases.

0.88.0

Breaking Changes

Code Generation Changes

  • Non-object allOf sites now generate the constrained value type instead of an empty model - Without --intersect-allof-keywords, some allOf sites used to be generated as an empty class (class TwoRefsProp(BaseModel): pass, or an empty Struct, dataclass or TypedDict) that rejected every valid value. These are sites whose parts admit no object, for example two integer $refs with a sibling minimum, a $ref to an array schema with minItems, or two string schemas with a pattern each. They are now generated as the intersected value type: a RootModel such as RootModel[conint(ge=3, le=5)] or RootModel[list[str]] for Pydantic v2, and a type alias for dataclasses, msgspec and TypedDict output (for example TwoPatterns: TypeAlias = str). Fields that referenced those classes change with them. Under msgspec or --collapse-root-models, some models are inlined or no longer emitted (for example two_prop: Annotated[int, Meta(ge=4, le=5)]). Merged lookaround patterns add model_config = ConfigDict(regex_engine="python-re") or a from re import compile import, and a nullable site is now typed as a union with None. Code that imports, subclasses or instantiates these former empty classes, or passes dicts to them, must be updated: valid scalar and array values now validate and objects are rejected (#5406)
  • Defaults of affected properties follow their new value type with --strip-default-none or --use-default-factory-for-optional-nested-models - A property whose allOf of scalar schemas used to be an empty model now gets the default its value type gets. --use-default-factory-for-optional-nested-models no longer emits a default factory for it, and --strip-default-none keeps the None default only where the type admits null. This can change whether these fields are required and the order of constructor arguments in generated models and dataclasses (#5406)
  • Client and server targets keep a schema's own null rejection when it is merged into a nullable model - With --generate-client or --generate-server combined with --reuse-model --collapse-reuse-models, a schema that does not admit null but is merged into an equal nullable model (for example a non-nullable Work collapsed into a nullable Home) no longer takes on the merged model's null. Operations and fields that name it now type their body or result as Home instead of Home | None. Generated client codecs refuse to send or accept None for them, and generated FastAPI servers reject a null request body and answer a bare None result with a 500. Callers or service implementations that passed or returned None there must be updated (#5480)

Error Handling Changes

  • Client and view default headers or query that patch a helper-written parameter are now refused - The generated Python client's pagination helpers (iterate, page, next_page), polling helpers (start, resume) and upload helpers (start, resume) used to reject only a call's own extra_headers or extra_query naming a header or query parameter the helper writes. They now also raise ConfigurationError before sending when the client's or a view's (with_options) default_headers or default_query names such a parameter, with a field_path of ("default_headers", name) or ("default_query", name). A client or view set up with such defaults, which used to send these requests, now fails; remove the conflicting default or use a client or view without it for helper calls. A count pagination helper's offset or page position is exempt: a client or view default of it is used as the first position, and only the call's own extra is still refused (#5502)

What's Changed

... (truncated)

Changelog

Sourced from datamodel-code-generator's changelog.

0.88.0 - 2026-11-02

Breaking Changes

Code Generation Changes

  • Non-object allOf sites now generate the constrained value type instead of an empty model - Without --intersect-allof-keywords, some allOf sites used to be generated as an empty class (class TwoRefsProp(BaseModel): pass, or an empty Struct, dataclass or TypedDict) that rejected every valid value. These are sites whose parts admit no object, for example two integer $refs with a sibling minimum, a $ref to an array schema with minItems, or two string schemas with a pattern each. They are now generated as the intersected value type: a RootModel such as RootModel[conint(ge=3, le=5)] or RootModel[list[str]] for Pydantic v2, and a type alias for dataclasses, msgspec and TypedDict output (for example TwoPatterns: TypeAlias = str). Fields that referenced those classes change with them. Under msgspec or --collapse-root-models, some models are inlined or no longer emitted (for example two_prop: Annotated[int, Meta(ge=4, le=5)]). Merged lookaround patterns add model_config = ConfigDict(regex_engine="python-re") or a from re import compile import, and a nullable site is now typed as a union with None. Code that imports, subclasses or instantiates these former empty classes, or passes dicts to them, must be updated: valid scalar and array values now validate and objects are rejected (#5406)
  • Defaults of affected properties follow their new value type with --strip-default-none or --use-default-factory-for-optional-nested-models - A property whose allOf of scalar schemas used to be an empty model now gets the default its value type gets. --use-default-factory-for-optional-nested-models no longer emits a default factory for it, and --strip-default-none keeps the None default only where the type admits null. This can change whether these fields are required and the order of constructor arguments in generated models and dataclasses (#5406)
  • Client and server targets keep a schema's own null rejection when it is merged into a nullable model - With --generate-client or --generate-server combined with --reuse-model --collapse-reuse-models, a schema that does not admit null but is merged into an equal nullable model (for example a non-nullable Work collapsed into a nullable Home) no longer takes on the merged model's null. Operations and fields that name it now type their body or result as Home instead of Home | None. Generated client codecs refuse to send or accept None for them, and generated FastAPI servers reject a null request body and answer a bare None result with a 500. Callers or service implementations that passed or returned None there must be updated (#5480)

Error Handling Changes

  • Client and view default headers or query that patch a helper-written parameter are now refused - The generated Python client's pagination helpers (iterate, page, next_page), polling helpers (start, resume) and upload helpers (start, resume) used to reject only a call's own extra_headers or extra_query naming a header or query parameter the helper writes. They now also raise ConfigurationError before sending when the client's or a view's (with_options) default_headers or default_query names such a parameter, with a field_path of ("default_headers", name) or ("default_query", name). A client or view set up with such defaults, which used to send these requests, now fails; remove the conflicting default or use a client or view without it for helper calls. A count pagination helper's offset or page position is exempt: a client or view default of it is used as the first position, and only the call's own extra is still refused (#5502)

What's Changed

... (truncated)

Commits
  • 1ebbfc2 Name where the walk finds a declared schema in one place (#5980)
  • c17dc43 Assemble the constraints of an object property and a root field, and lay out ...
  • 170d961 Spell the recommendation words, select a BaseModel's regex engine, read the i...
  • eca0cb4 Tell whether a rewrite changed nothing, pick the compiled renderer, write a p...
  • d7410f9 Build the id of a schema's own use, tell whether reuse made a model and name ...
  • b538521 Write the array an itemSchema stands for, parse the schema of a media type, r...
  • a79a18c Lay out the brackets and nested entries of a literal and map a field's facts ...
  • d2f11f0 Pick the field whose default an inherited field override takes, tell which dr...
  • cbf45ad Take the arguments of a code formatter from the model settings, check the sch...
  • 73e8052 Build the type a Python type expression spells in one place (#5954)
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [datamodel-code-generator](https://github.com/datamodel-code-generator/datamodel-code-generator) from 0.31.2 to 0.88.0.
- [Release notes](https://github.com/datamodel-code-generator/datamodel-code-generator/releases)
- [Changelog](https://github.com/datamodel-code-generator/datamodel-code-generator/blob/main/CHANGELOG.md)
- [Commits](datamodel-code-generator/datamodel-code-generator@0.31.2...0.88.0)

---
updated-dependencies:
- dependency-name: datamodel-code-generator
  dependency-version: 0.88.0
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot added dependencies Pull requests that update a dependency file python Pull requests that update python code labels Nov 6, 2026
@dependabot @github

dependabot Bot commented on behalf of github Nov 9, 2026

Copy link
Copy Markdown
Author

Superseded by #1027.

@dependabot dependabot Bot closed this Nov 9, 2026
@dependabot
dependabot Bot deleted the dependabot/pip/sdk/python/datamodel-code-generator-0.88.0 branch November 9, 2026 03:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file python Pull requests that update python code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants