Doesn't this mean that the locality preferences for the task set are completely ignored?  Given that, why do you need to use locality preferences when creating the task set on line 315?