striplog/rock.py
def Rock(*args, **kwargs):
    """
    Graceful deprecation for old class name.
    """

    with warnings.catch_warnings():
        warnings.simplefilter("always")
        w = "The 'Rock' class was renamed 'Component'. "
        w += "Please update your code."
        warnings.warn(w, DeprecationWarning, stacklevel=2)

    return Component(*args, **kwargs)
def Rock(*args, **kwargs):
    with warnings.catch_warnings():
        warnings.simplefilter("always")
        w = "The 'Rock' class was renamed 'Component'. "
        w += "Please update your code."
        warnings.warn(w, DeprecationWarning, stacklevel=2)

    return Component(*args, **kwargs)
def Rock ( * args , * * kwargs ) : with warnings . catch_warnings ( ) : warnings . simplefilter ( "always" ) w = "The 'Rock' class was renamed 'Component'. " w += "Please update your code." warnings . warn ( w , DeprecationWarning , stacklevel = 2 ) return Component ( * args , * * kwargs )
Graceful deprecation for old class name.
Graceful deprecation for old class name .