Skip to content

Conversation

daniel-kmiecik
Copy link
Contributor

Description of the PR

Before bugfix: a required and nullable attribute set to null/None causes a ValueError when received by the client.
After bugfix: This error is only caused for properties being required and not nullable
General info: The python client cannot distinguish between unset attributes (value=None) and attributes set to null (value=None)

Issue to solve with a good description of the bug:

closes: #10535
closes: #8710

PR checklist

Performed tests:

Tested with own api-specs and the swagger-cli:

  • The generation works.
  • The two lines causing the error are removed in the python client, nothing else changes.

Before bugfix: a required and nullable attribute set to null/None causes a value error when received by the client.
After bugfix: This error is only caused for properties being required and not nullable
General info: The python client cannot distinguish between unset attributes (value=None) and attributes set to null (value=None)
@daniel-kmiecik
Copy link
Contributor Author

Author: @MalteEbner

@daniel-kmiecik daniel-kmiecik merged commit b111ab8 into master Oct 8, 2025
5 checks passed
@daniel-kmiecik daniel-kmiecik deleted the python-fix branch October 8, 2025 10:22
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.

[PYTHON] Generated code disregards nullable flag [Python] Generated code does not respect nullable values

3 participants