Yikes that's definitely a bug, although we did this sort of thing a lot back in 2016 when the code was first written. Ideally we wouldn't poll at all, tasks are only unregistered in one place so we should just be able to subscribe to an event triggered from there.
Originally posted by @DaveCTurner in #89564 (comment)
Originally posted by @DaveCTurner in #89564 (comment)