modelity.unset

modelity.unset.Unset: Final = Unset

Singleton instance of the UnsetType.

class modelity.unset.UnsetType

Bases: object

Singleton type for representing unset or undefined values.

It has only one global instance to allow fast is-a tests in the code and always evaluates to False.

__bool__()
static __new__(cls)
__repr__()

Return repr(self).

__slots__: list = []
modelity.unset.is_unset(obj: object) TypeIs[UnsetType]

Check if obj is instance of UnsetType type.

Changed in version 0.31.0: Now uses typing_extensions.TypeIs for type narrowing.

Added in version 0.17.0.