zedfmario commented on issue #46824:
URL: https://github.com/apache/airflow/issues/46824#issuecomment-3031974849

   @ninsbl I was playing a bit with version `2.10.5` and the 
`PriorityWeightStrategy`, ending up in here. Although I didn't manage to get 
rid of the _webserver's_ notification 
   > ```
   >[...] is not one of ['downstream', 'upstream', 'absolute'] 
   > Failed validating 'enum' in schema['properties']['weight_rule']: 
   > {'description': 'Weight rule.', 'type': 'string', 'enum': ['downstream', 
'upstream',' absolute']} On instance['weight_rule']```
   
   I did manage to set the weights "properly", but only after the second time I 
cleared the tasks and with some sort of delay. Let me show my case.
   
   In a `@daily` DAG, the very first time tasks are queued, they have a 
"default" weight. They are `ti.dag_run.data_interval_start` dependent, so every 
day we will get the same value. I expected that clearing the tasks would 
recompute the weights, but that's done on `runtime` after they are actually 
scheduled and running, so the second try gets in the queue with the former 
value, not the updated one. 
   
   Third time (`try_run == 2`)  the values are those calculated in the previous 
clear... So I'm always delayed by one run... 
   
   Any idea how to deal with that? 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to