docs: def all_subclasses(cls):
      """
      Given a class `cls`, this recursive function returns a list with
      all subclasses, subclasses of subclasses, and so on.
      """
      subclasses = cls.__subclasses__() 
      return subclasses + [g for s in subclasses for g in all_subclasses(s)]