

def _get_type(self, statobj):
    'Determine file type from stat object `statobj`.\n        Distinguish file, dir, symbolic link.\n        '
    if stat.S_ISREG(statobj.st_mode):
        return 'file'
    if stat.S_ISDIR(self.st_mode):
        return 'dir'
    if stat.S_ISLNK(statobj.st_mode):
        return 'symlink'
    raise TimegapsError("Unsupported file type: '%s'", self.path)

dataset/ETHPy150Open jgehrcke/timegaps/timegaps/timegaps.py FileSystemEntry._get_type/VarMisuse@35/86 `statobj`->`self`