def is_serializable(value: Any) -> bool:
    """Check if a value is serializable.

    Args:
        value: The value to check.

    Returns:
        Whether the value is serializable.
    """
    try:
        return bool(pickle.dumps(value))
    except Exception:
        return False
Check if a value is serializable.

    Args:
        value: The value to check.

    Returns:
        Whether the value is serializable.
    
reflex/state.py