code: def pids():
      ls = cext.pids()
      if 0 not in ls:
          # On certain macOS versions pids() C doesn't return PID 0 but
          # "ps" does and the process is querable via sysctl():
          # https://travis-ci.org/giampaolo/psutil/jobs/309619941
          try:
              Process(0).create_time()
              ls.insert(0, 0)
          except NoSuchProcess:
              pass
          except AccessDenied:
              ls.insert(0, 0)
      return ls
  
imports: import contextlib
  import errno
  import functools
  import os
  from collections import namedtuple
  from .None import _common
  from .None import _psposix
  from .None import _psutil_osx
  from .None import _psutil_posix
  from ._common import AccessDenied
  from ._common import conn_tmap
  from ._common import conn_to_ntuple
  from ._common import isfile_strict
  from ._common import memoize_when_activated
  from ._common import NoSuchProcess
  from ._common import parse_environ_block
  from ._common import usage_percent
  from ._common import ZombieProcess
  from ._compat import PermissionError
  from ._compat import ProcessLookupError
label_desc: Use image node_id 15 for calling a global function with example usage: pids() and returns: ls