code: def has_magic(s):
      if isinstance(s, bytes):
          match = magic_check_bytes.search(s)
      else:
          match = magic_check.search(s)
      return match is not None
  
imports: import contextlib
  import os
  import re
  import fnmatch
  import itertools
  import stat
  import sys
label_desc: Use image node_id 15 for calling a global function with example usage: has_magic(s) and returns: unknown