nat.experimental.decorators.experimental_warning_decorator#
Attributes#
Functions#
|
Log a warning message that the function is experimental. |
|
Decorator that can wrap any type of function (sync, async, generator, |
Module Contents#
- logger#
- BASE_WARNING_MESSAGE = 'is experimental and the API may change in future releases. Future versions may introduce...#
- _warning_issued#
- F#
- issue_experimental_warning( )#
Log a warning message that the function is experimental.
A warning is emitted only once per function. When a
metadatadict is supplied, it is appended to the log entry to provide extra context (e.g., version, author, feature flag).
- experimental( ) F#
- experimental( ) collections.abc.Callable[[F], F]
Decorator that can wrap any type of function (sync, async, generator, async generator) and logs a warning that the function is experimental.
- Args:
func: The function to be decorated. feature_name: Optional name of the feature that is experimental. If provided, the warning will be prefixed with “The <feature_name> feature is experimental”. metadata: Optional dictionary of metadata to log with the warning. This can include information like version, author, etc. If provided, the metadata will be logged alongside the experimental warning.
- aiq_experimental#