def METHOD_NAME(cls, category: str, alias: str, obj: Any) -> None:
    if not isinstance(alias, str):
        raise TypeError(
            "Aliases must be strings, given {category} entry {alias!r} of type {typ} as "
            "the alias of {obj}".format(
                category=category, alias=alias, typ=type(alias).__name__, obj=obj
            )
        )