Skip to main content

warn

Warn of (pending) deprecation.

def warn(
description: string = None,
deprecation: string = None,
removal: string = None,
alternative: string = None,
stacklevel: integer = 2
) - > null

Warn of (pending) deprecation.

Parameters

NameTypeDescription
descriptionstring = NoneA brief explanation of the feature or behavior being deprecated.
deprecationstring = NoneThe version or date when the feature was first marked as deprecated; if provided, a pending deprecation warning is issued.
removalstring = NoneThe version or date when the feature is scheduled to be removed from the codebase.
alternativestring = NoneA suggested replacement or alternative approach for callers to use instead of the deprecated feature.
stacklevelinteger = 2The number of stack frames to skip when reporting the warning location, ensuring the warning points to the caller.

Returns

TypeDescription
nullNothing; this function issues a warning to the standard warning system.