code: def _get_positional_arg_names(func: "Callable[_P, _T]") -> list[str]:
      params = signature(func).parameters
      positional_arg_names = [
          name
          for name, p in params.items()
          if p.default == Parameter.empty
          and p.kind == p.POSITIONAL_OR_KEYWORD
      ]
      return positional_arg_names
  
file_path: optuna/optuna/_convert_positional_args.py
imports: from __future__ import annotations
  from collections.abc import Callable
  from collections.abc import Sequence
  from functools import wraps
  from inspect import Parameter
  from inspect import signature
  from typing import Any
  from typing import TYPE_CHECKING
  from typing import TypeVar
  import warnings
label_desc: Use image node_id 1 for calling a global function with example usage: _get_positional_arg_names(func) and returns: positional_arg_names