Skip to content

Conversation

@luci-bytes
Copy link

@luci-bytes luci-bytes commented Nov 25, 2025

Solves #371

The configuration in the pyproject.toml now takes the additional setting ignore_extra_fields. ignore_extra_fields is true by default as BaseModel ignores extra fields by default. If it is set to false, extra='forbid' will be appended to the BaseModel in the client. If additional fields are then provided, an error is thrown.

Additionally three unit tests have been added, which test:

  • If extra='forbid' is properly appended if no extra is provided
  • If extra='ignore' is not overriden, in case it exists
  • If other classes in the provided code are left untouched

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.

1 participant