You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using a multitude of annotations to specify where the task shall end up, this creates certain incompatibilities, in particular with resources. The following test causes a KeyError since the task is transitioned prematurely to a waiting state.
(What I actually wanted to do in this test is "Never execute on B" which is why I chose this construction but that is not the point here)
I believe there is a semantic misalignment in here since the resources are actually treated as a hard requirement, regardless of whether the allow_other_workers is set or not. I believe this is a sane behaviour since we otherwise cannot really tell whether we should or should not subtract anything. I'm wondering if the meaning of the flag allow_other_workers should be redefined. For some of the fields it may make sense (e.g. workers) but for things like host restrictions or resource restrictions this doesn't feel sensible to me.
The below exception should be "easily" fixable but the intended behaviour is unclear to me.
Looking at our own documentation it is already clear that there is some misalignment. I would argue that the definition of allow_other_workers makes sense but the loose_restrictions label is a bit ill defined, or at the very least not in alignment with the flag
I've recently run into this as well, specifically in the context of work-stealing from workers with restrictions where the tasks had been scheduled on a particular worker with allow_other_workers=True. From the docs, I would have assumed that tasks may get stolen but only onto workers fulfilling the resource restrictions.
When using a multitude of annotations to specify where the task shall end up, this creates certain incompatibilities, in particular with
resources
. The following test causes aKeyError
since the task is transitioned prematurely to a waiting state.(What I actually wanted to do in this test is "Never execute on B" which is why I chose this construction but that is not the point here)
I believe there is a semantic misalignment in here since the resources are actually treated as a hard requirement, regardless of whether the
allow_other_workers
is set or not. I believe this is a sane behaviour since we otherwise cannot really tell whether we should or should not subtract anything. I'm wondering if the meaning of the flagallow_other_workers
should be redefined. For some of the fields it may make sense (e.g.workers
) but for things like host restrictions or resource restrictions this doesn't feel sensible to me.The below exception should be "easily" fixable but the intended behaviour is unclear to me.
Looking at our own documentation it is already clear that there is some misalignment. I would argue that the definition of
allow_other_workers
makes sense but theloose_restrictions
label is a bit ill defined, or at the very least not in alignment with the flagSee
distributed/distributed/client.py
Lines 1520 to 1522 in 27e5925
distributed/distributed/scheduler.py
Lines 1240 to 1251 in 27e5925
The text was updated successfully, but these errors were encountered: