1.7 KiB

title slug
Utils /sdk/python/api-reference/utils

{% image align="right" style="float:right;" src="https://img.shields.io/badge/-source-cccccc?style=flat-square" /%}

module utils

Helper functions to handle OpenMetadata Entities' properties


{% image align="right" style="float:right;" src="https://img.shields.io/badge/-source-cccccc?style=flat-square" /%}

function format_name

format_name(name: str)  str

Given a name, replace all special characters by _ :param name: name to format :return: formatted string


{% image align="right" style="float:right;" src="https://img.shields.io/badge/-source-cccccc?style=flat-square" /%}

function get_entity_type

get_entity_type(entity: Union[Type[~T], str])  str

Given an Entity T, return its type. E.g., Table returns table, Dashboard returns dashboard...

Also allow to be the identity if we just receive a string


{% image align="right" style="float:right;" src="https://img.shields.io/badge/-source-cccccc?style=flat-square" /%}

function model_str

model_str(arg: Any)  str

Default model stringifying method.

Some elements such as FQN, EntityName, UUID have the actual value under the pydantic base root