code: def get_output_error_code(cmd):
      """Get stdout, stderr, and exit code from running a command"""
      p = Popen(cmd, stdout=PIPE, stderr=PIPE)
      out, err = p.communicate()
      out = out.decode("utf8", "replace")
      err = err.decode("utf8", "replace")
      return out, err, p.returncode
  
imports: import sys
  from subprocess import Popen, PIPE
label_desc: Use image node_id 1 for calling a global function with example usage: get_output_error_code(cmd) and returns: out,  err,  p