code: def get_signal_handler(job: Job) -> job_environment.SignalHandler:
      env = slurm.SlurmJobEnvironment()
      delayed = utils.DelayedSubmission.load(job.paths.submitted_pickle)
      sig = job_environment.SignalHandler(env, job.paths, delayed)
      return sig
  
imports: import contextlib
  import os
  import signal
  import subprocess
  import typing
  from pathlib import Path
  from unittest.mock import patch
  import pytest
  import submitit
  from ..None import helpers
  from ..core import job_environment, submission, test_core, utils
  from ..core.core import Job
  from .None import slurm
label_desc: Use image node_id 9 for calling a global function with example usage: get_signal_handler(job) and returns: sig