Check the status of an open path.  Note that we have to use stat() rather
        than fstat() because we want to detect file removes and renames.

def _poll_get_stat(self, fd, path):
        """
        Check the status of an open path.  Note that we have to use stat() rather
        than fstat() because we want to detect file removes and renames.
    """
        try:
            st = os.stat(path)
            fstate = (st.st_mode, st.st_nlink, st.st_uid, st.st_gid, st.st_size, st.st_mtime)
        except Exception as e:
            log = self._getparam('log', self._discard)
            log.debug("stat failed on %s -- %s", path, e)
            self._poll_pending[path] = time.time()
            self._disappeared(fd, path)
            fstate = None
        return fstate