-
Notifications
You must be signed in to change notification settings - Fork 16.4k
Closed
Labels
AIP-84Modern Rest APIModern Rest APIarea:APIAirflow's REST/HTTP APIAirflow's REST/HTTP APIgood first issuekind:featureFeature RequestsFeature Requests
Milestone
Description
Description
None Values
Currently, the handling of None values in PATCH requests is inconsistent across different parts of the codebase. In some instances, when no mask is provided, None values are filtered out, while in others, such as the Pool model, all values (including None) are validated and persisted if the payload is valid. The objective of this work item is to standardize PATCH request behaviour regarding None values:
- When a mask is provided, use the values as specified by the mask.
- When no mask is provided, ensure the payload is validated independently as a fully-formed database entity, allowing for explicit setting of fields to None.
Database Calls
Avoid making database calls solely to check for existence; instead, delegate this responsibility to the database itself during the primary operation.
Use case/motivation
A standardized approach for PATCH endpoints is needed.
Related issues
Relates to: #42370
Follow Up of: #43102
Are you willing to submit a PR?
- Yes I am willing to submit a PR!
Code of Conduct
- I agree to follow this project's Code of Conduct
rawwar
Metadata
Metadata
Assignees
Labels
AIP-84Modern Rest APIModern Rest APIarea:APIAirflow's REST/HTTP APIAirflow's REST/HTTP APIgood first issuekind:featureFeature RequestsFeature Requests