class_docstr: Parallel Python SMP execution server class
      
class_docstr_tok: ["Parallel","Python","SMP","execution","server","class"]
docstr: Runs a job locally
docstr_tok: ["Runs","a","job","locally"]
code: def _run_local(self, job, sfunc, sargs, worker):
      """Runs a job locally"""
  
      if self._exiting:
          return
      self.logger.info("Task %i started", job.tid)
  
      start_time = time.time()
  
      try:
          # open('/tmp/pp.debug', 'a+').write('_local: %s\n' % repr(sfunc))
          worker.t.csend(sfunc)
          # open('/tmp/pp.debug', 'a+').write('_local: %s\n' % repr(sargs))
          worker.t.send(sargs)
          # open('/tmp/pp.debug', 'a+').write('_local: \n')
          sresult = worker.t.receive()
          # open('/tmp/pp.debug', 'a+').write('_local: %s\n' % repr(sresult))
          job.finalize(sresult)
      # open('/tmp/pp.debug', 'a+').write('_local: _\n')
      except:
          if self._exiting:
              return
          if SHOW_EXPECTED_EXCEPTIONS:
              self.logger.debug(
                  "Exception in _run_local (possibly expected)",
                  exc_info=True,
              )
  
      # remove the job from the waiting list
      if self.__waittasks:
          self.__waittasks_lock.acquire()
          self.__waittasks.remove(job)
          self.__waittasks_lock.release()
  
      worker.free()
  
      self.__add_to_active_tasks(-1)
      if not self._exiting:
          self.__stat_add_time("local", time.time() - start_time)
      self.logger.debug("Task %i ended", job.tid)
      self.__scheduler()
  
imports: import os
  import threading
  import logging
  import inspect
  import sys
  import types
  import time
  import atexit
  from .None import transport
  from .None import auto
  from .None import common
  import subprocess
label_desc: Use image node_id 17 for calling the Server obj's underlying member method code with example usage: obj._run_local(job, sfunc, sargs, worker) without return types