Pool API improve slots validation#61071
Conversation
jason810496
left a comment
There was a problem hiding this comment.
It seems -1 is still supported for pools, as it is treated as infinite. So maybe we should allow positive integers and -1 for the slots field.
airflow/airflow-core/src/airflow/models/pool.py
Lines 90 to 91 in bb0ff04
airflow/airflow-core/src/airflow/models/pool.py
Lines 216 to 222 in bb0ff04
|
Arf, yes there is that |
|
Ok, after more thoughts, lets merge this for now, which is better than no validation at all. Currently -1 is not possible to use via the API, because it will be returned as I'll create a separate issue for that. |
(cherry picked from commit 4a0364a) Co-authored-by: Pierre Jeambrun <pierrejbrun@gmail.com>
|
Issue here #61115 |
Add backend validation to pool API on slots attribute. It is not possible anymore to create or update pools slots to have null or negative values.