def METHOD_NAME(self):
    # pylint:disable=method-hidden
    # Do this only once, at the end.
    to_join = set(threading.enumerate()) - set(self._old_threads)
    for t in to_join:
        try:
            t.join(10)
        except RuntimeError: # pragma: no cover
            # If the thread wasn't actually started; if we got some random exception,
            # this might happen.
            print("Joining unstarted thread", t, file=sys.stderr)
            traceback.print_exc()
    self.METHOD_NAME = lambda: None