maybe_qualified_type_name

maybe_qualified_type_name#

treescope.rendering_parts.maybe_qualified_type_name(ty: type[Any]) RenderableTreePart[source]#

Formats the name of a type so that it is qualified in roundtrip mode.

Parameters:

ty – A type object to render.

Returns:

A tree part that renders as a fully-qualified name in roundtrip mode, or as the simple class name otherwise. Module names will be either inferred from the type’s definition or looked up using canonical_aliases.