If an unreachable agent is marked as gone, currently master just marks that agent in the registry but doesn't do anything about its tasks. So the tasks are in UNREACHABLE state in the master forever, until the master fails over. This is not great UX. We should transition these to terminal state instead.
This fix should also include a test to verify.