compat Module (stx.compat)
SciTeX Backward Compatibility Module.
This module provides aliases and wrappers for deprecated APIs. Import from here to use old function names that delegate to new implementations.
Deprecation Timeline: - v1.x: Old APIs work with deprecation warnings - v2.x: Old APIs removed, use new APIs directly
- scitex.compat.deprecated(reason=None, forward_to=None)[source]
Mark a function as deprecated, optionally forwarding calls to its replacement.
Canonical SSOT for the ecosystem (see SOC.md). Pure stdlib — safe for any Layer 0 leaf to import without dragging numpy / scitex-decorators.
- Parameters:
reason (str, optional) – Human-readable explanation of why the function was deprecated.
forward_to (str, optional) – Dotted module path to the replacement, e.g.
"..session.start"or"scitex.session.start". When provided, calls are forwarded to the new function (viaimportlib) and the wrapper’s docstring is auto-generated by combining a deprecation notice with the target’s docstring. Relative paths starting with..are resolved against the decorated function’s__module__.