VaKeR CYBER ARMY
Logo of a company Server : Apache/2.4.41 (Ubuntu)
System : Linux absol.cf 5.4.0-198-generic #218-Ubuntu SMP Fri Sep 27 20:18:53 UTC 2024 x86_64
User : www-data ( 33)
PHP Version : 7.4.33
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Directory :  /usr/local/lib/python3.8/dist-packages/setproctitle/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //usr/local/lib/python3.8/dist-packages/setproctitle/__init__.py
"""Allow customization of the process title."""

import os
import sys
import logging

logger = logging.getLogger("setproctitle")

__version__ = "1.3.4"

__all__ = [
    "setproctitle",
    "getproctitle",
    "setthreadtitle",
    "getthreadtitle",
]


def setproctitle(title: str) -> None:
    logger.debug("setproctitle C module not available")
    return None


def getproctitle() -> str:
    logger.debug("setproctitle C module not available")
    return " ".join(sys.argv)


def setthreadtitle(title: str) -> None:
    logger.debug("setproctitle C module not available")
    return None


def getthreadtitle() -> str:
    logger.debug("setproctitle C module not available")
    return ""


try:
    from . import _setproctitle  # type: ignore
except ImportError as e:
    # Emulate SPT_DEBUG showing process info in the C module.
    if os.environ.get("SPT_DEBUG", ""):
        logging.basicConfig()
        logger.setLevel(logging.DEBUG)
    logger.debug("failed to import setproctitle: %s", e)
else:
    setproctitle = _setproctitle.setproctitle  # noqa: F811
    getproctitle = _setproctitle.getproctitle  # noqa: F811
    setthreadtitle = _setproctitle.setthreadtitle  # noqa: F811
    getthreadtitle = _setproctitle.getthreadtitle  # noqa: F811


# Call getproctitle to initialize structures and avoid problems caused
# by fork() on macOS (see #113).
if sys.platform == "darwin":
    getproctitle()

VaKeR 2022