$96 GRAYBYTE WORDPRESS FILE MANAGER $84

SERVER : premium201.web-hosting.com #1 SMP Wed Mar 26 12:08:09 UTC 2025
SERVER IP : 172.67.162.162 | ADMIN IP 216.73.216.174
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : NONE

/opt/cloudlinux/venv/lib/python3.11/site-packages/clcommon/cpapi/

HOME
Current File : /opt/cloudlinux/venv/lib/python3.11/site-packages/clcommon/cpapi//utils.py
import sys
from functools import wraps
from clcommon.const import Feature
from clcommon.cpapi import is_panel_feature_supported

from clcommon.lib.cledition import (
    CLEditionDetectionError,
)

__all__ = (
    "skip_without_lve",
    "lve_supported_or_exit",
)


_SKIP_MESSAGE = (
    "Command is skipped as LVE feature is not supported in current environment\n"
    "Refer to https://docs.cloudlinux.com/solo/introduction/#cloudlinux-os-editions-comparison for more info"
)


def skip_without_lve():
    try:
        # we still have some utils that could be run
        # under user (e.g cloudlinux-selector)
        if not is_panel_feature_supported(Feature.LVE):
            print(_SKIP_MESSAGE)
            sys.exit(0)
    except CLEditionDetectionError as e:
        print(f"Error: {e}")
        sys.exit(1)


def lve_supported_or_exit(f):
    @wraps(f)
    def inner(*args, **kwargs):
        if not is_panel_feature_supported(Feature.LVE):
            print(_SKIP_MESSAGE)
        else:
            return f(*args, **kwargs)

    return inner


Current_dir [ NOT WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
9 Apr 2026 8.30 AM
root / root
0755
GeneralPanel
--
9 Apr 2026 8.30 AM
root / root
0755
__pycache__
--
9 Apr 2026 8.30 AM
root / root
0755
cache
--
9 Apr 2026 8.30 AM
root / root
0755
plugins
--
9 Apr 2026 8.30 AM
root / root
0755
__init__.py
14.852 KB
13 Mar 2026 7.40 PM
root / root
0644
apilink.py
0.034 KB
9 Apr 2026 8.30 AM
root / root
0644
clcpapi.py
3.643 KB
13 Mar 2026 7.40 PM
root / root
0644
const.py
0.499 KB
13 Mar 2026 7.40 PM
root / root
0644
cpapicustombin.py
2.123 KB
13 Mar 2026 7.40 PM
root / root
0644
cpapiexceptions.py
1.748 KB
13 Mar 2026 7.40 PM
root / root
0644
cpapirebuildcache
0.46 KB
13 Mar 2026 7.40 PM
root / root
0644
panel_hooks_lib.py
1.225 KB
13 Mar 2026 7.40 PM
root / root
0644
pluginlib.py
7.57 KB
13 Mar 2026 7.40 PM
root / root
0644
utils.py
1.029 KB
13 Mar 2026 7.40 PM
root / root
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025 CONTACT ME
Static GIF