Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions gprofiler/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@
grab_gprofiler_mutex,
is_root,
reset_umask,
resource_path,
run_process,
)
from gprofiler.utils.fs import resource_path
from gprofiler.utils.process import run_process
from gprofiler.utils.proxy import get_https_proxy

logger: logging.LoggerAdapter
Expand Down
2 changes: 1 addition & 1 deletion gprofiler/metadata/application_identifiers.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
from gprofiler.log import get_logger_adapter
from gprofiler.metadata.enrichment import EnrichmentOptions
from gprofiler.profilers.java import jattach_path
from gprofiler.utils import run_process
from gprofiler.utils.process import run_process

_logger = get_logger_adapter(__name__)

Expand Down
3 changes: 2 additions & 1 deletion gprofiler/metadata/system_metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
from granulate_utils.linux.ns import run_in_ns

from gprofiler.log import get_logger_adapter
from gprofiler.utils import is_pyinstaller, run_process
from gprofiler.utils import is_pyinstaller
from gprofiler.utils.process import run_process

UNKNOWN_VALUE = "unknown"

Expand Down
2 changes: 1 addition & 1 deletion gprofiler/metadata/versions.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from granulate_utils.linux.ns import get_process_nspid, run_in_ns
from psutil import Process

from gprofiler.utils import run_process
from gprofiler.utils.process import run_process


def get_exe_version(
Expand Down
5 changes: 3 additions & 2 deletions gprofiler/profilers/dotnet.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@
from gprofiler.metadata.application_metadata import ApplicationMetadata
from gprofiler.profilers.profiler_base import ProcessProfilerBase
from gprofiler.profilers.registry import register_profiler
from gprofiler.utils import pgrep_maps, random_prefix, removed_path, resource_path, run_process
from gprofiler.utils.process import is_process_basename_matching, process_comm
from gprofiler.utils.fs import resource_path
from gprofiler.utils.process import pgrep_maps, is_process_basename_matching, process_comm, run_process
from gprofiler.utils.speedscope import load_speedscope_as_collapsed
from gprofiler.utils.fs import removed_path, random_prefix

logger = get_logger_adapter(__name__)

Expand Down
10 changes: 2 additions & 8 deletions gprofiler/profilers/java.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,17 +55,11 @@
from gprofiler.utils import (
GPROFILER_DIRECTORY_NAME,
TEMPORARY_STORAGE_PATH,
pgrep_maps,
remove_path,
remove_prefix,
resource_path,
run_process,
touch_path,
wait_event,
)
from gprofiler.utils.fs import is_rw_exec_dir, safe_copy
from gprofiler.utils.fs import is_rw_exec_dir, safe_copy, remove_prefix, touch_path, remove_path, resource_path
from gprofiler.utils.perf import can_i_use_perf_events
from gprofiler.utils.process import is_process_basename_matching, process_comm, search_proc_maps
from gprofiler.utils.process import pgrep_maps, is_process_basename_matching, process_comm, search_proc_maps, run_process

logger = get_logger_adapter(__name__)

Expand Down
4 changes: 3 additions & 1 deletion gprofiler/profilers/node.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@

from gprofiler.log import get_logger_adapter
from gprofiler.metadata.versions import get_exe_version
from gprofiler.utils import TEMPORARY_STORAGE_PATH, add_permission_dir, pgrep_exe, resource_path
from gprofiler.utils import TEMPORARY_STORAGE_PATH, add_permission_dir
from gprofiler.utils.fs import resource_path
from gprofiler.utils.process import pgrep_exe

logger = get_logger_adapter(__name__)

Expand Down
5 changes: 3 additions & 2 deletions gprofiler/profilers/perf.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,10 @@
from gprofiler.profilers.node import clean_up_node_maps, generate_map_for_node_processes, get_node_processes
from gprofiler.profilers.profiler_base import ProfilerBase
from gprofiler.profilers.registry import ProfilerArgument, register_profiler
from gprofiler.utils import run_process, start_process, wait_event, wait_for_file_by_prefix
from gprofiler.utils import wait_event
from gprofiler.utils.perf import perf_path
from gprofiler.utils.process import is_process_basename_matching
from gprofiler.utils.process import is_process_basename_matching, start_process, run_process
from gprofiler.utils.fs import wait_for_file_by_prefix

logger = get_logger_adapter(__name__)

Expand Down
4 changes: 3 additions & 1 deletion gprofiler/profilers/php.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@
from gprofiler.log import get_logger_adapter
from gprofiler.profilers.profiler_base import ProfilerBase
from gprofiler.profilers.registry import ProfilerArgument, register_profiler
from gprofiler.utils import random_prefix, resource_path, start_process, wait_event
from gprofiler.utils import wait_event
from gprofiler.utils.process import start_process
from gprofiler.utils.fs import random_prefix, resource_path

logger = get_logger_adapter(__name__)
# Currently tracing only php-fpm, TODO: support mod_php in apache.
Expand Down
4 changes: 2 additions & 2 deletions gprofiler/profilers/python.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@
if not is_windows():
from gprofiler.profilers.python_ebpf import PythonEbpfProfiler, PythonEbpfError

from gprofiler.utils import pgrep_maps, random_prefix, removed_path, resource_path, run_process
from gprofiler.utils.process import is_process_basename_matching, process_comm, search_proc_maps
from gprofiler.utils.fs import removed_path, remove_prefix, resource_path
from gprofiler.utils.process import pgrep_maps, is_process_basename_matching, process_comm, search_proc_maps, run_process

logger = get_logger_adapter(__name__)

Expand Down
12 changes: 3 additions & 9 deletions gprofiler/profilers/python_ebpf.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,9 @@
from gprofiler.metadata import application_identifiers
from gprofiler.profilers import python
from gprofiler.profilers.profiler_base import ProfilerBase
from gprofiler.utils import (
poll_process,
random_prefix,
resource_path,
run_process,
start_process,
wait_event,
wait_for_file_by_prefix,
)
from gprofiler.utils import wait_event
from gprofiler.utils.process import start_process, poll_process, run_process
from gprofiler.utils.fs import wait_for_file_by_prefix, random_prefix, resource_path

logger = get_logger_adapter(__name__)

Expand Down
4 changes: 2 additions & 2 deletions gprofiler/profilers/ruby.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
from gprofiler.metadata.application_metadata import ApplicationMetadata
from gprofiler.profilers.profiler_base import SpawningProcessProfilerBase
from gprofiler.profilers.registry import register_profiler
from gprofiler.utils import pgrep_maps, random_prefix, removed_path, resource_path, run_process
from gprofiler.utils.process import is_process_basename_matching, process_comm, search_proc_maps
from gprofiler.utils.fs import removed_path, random_prefix, resource_path
from gprofiler.utils.process import pgrep_maps, is_process_basename_matching, process_comm, search_proc_maps, run_process

logger = get_logger_adapter(__name__)

Expand Down
Loading