code: def identify_gwf(origin, filepath, fileobj, *args, **kwargs):
      
      # pylint: disable=unused-argument
  
      # try and read file descriptor
      if fileobj is not None:
          loc = fileobj.tell()
          fileobj.seek(0)
          try:
              if fileobj.read(4) == GWF_SIGNATURE:
                  return True
          finally:
              fileobj.seek(loc)
      if filepath is not None:
          if filepath.endswith('.gwf'):
              return True
          if filepath.endswith(('.lcf', '.cache')):
              try:
                  cache = read_cache(filepath)
              except IOError:
                  return False
              else:
                  if cache[0].path.endswith('.gwf'):
                      return True
docs: Identify a filename or file object as GWF
  
      This function is overloaded in that it will also identify a cache file
      as 'gwf' if the first entry in the cache contains a GWF file extension