[ 
https://issues.apache.org/jira/browse/AIRFLOW-4547?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16867432#comment-16867432
 ] 

Ash Berlin-Taylor commented on AIRFLOW-4547:
--------------------------------------------

Does this make it wrong?

If I have two tasks with priority of -1 and 1 then the -1 is lower, similar to 
two tasks with priorities of 1 and 2 where 1 is lower.

> Negative priority_weight should not be permitted
> ------------------------------------------------
>
>                 Key: AIRFLOW-4547
>                 URL: https://issues.apache.org/jira/browse/AIRFLOW-4547
>             Project: Apache Airflow
>          Issue Type: Bug
>          Components: operators
>    Affects Versions: 1.10.3
>            Reporter: Teresa Martyny
>            Priority: Major
>             Fix For: 1.10.4
>
>
> Airflow allows a dev to assign a negative priority_weight to a task. However, 
> the Airflow code does math to determine the priority_weight on its own in 
> models.py#priority_weight_total on line 2796
> This makes the final priority_weight wrong in the end. Airflow should raise 
> an error if an operator has priority_weight assigned to a negative number at 
> any point. 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to