code: def _run_attr_cmp(x, y, attr):
      if attr.startswith("-"):
          attr = attr[1:]
          rev = -1
      else:
          rev = 1
      x_val = _run_attr(x, attr)
      if x_val is None:
          return -rev
      y_val = _run_attr(y, attr)
      if y_val is None:
          return rev
      return rev * ((x_val > y_val) - (x_val < y_val))
  
imports: import errno
  import functools
  import logging
  import os
  import shutil
  import tempfile
  from guild import config
  from guild import run
  from guild import util
label_desc: Use image node_id 23 for calling a global function with example usage: _run_attr_cmp(x, y, attr) and returns: unknown, unknown, rev