mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-06 14:04:26 +08:00
Fix some directory issues
This commit is contained in:
@@ -71,7 +71,7 @@ class ZipFileIO(file_io.KnownContentFileIO, FileIOFolderMixin):
|
||||
def get_last_modified(self):
|
||||
try:
|
||||
return os.path.getmtime(self._zip_path)
|
||||
except (FileNotFoundError, PermissionError):
|
||||
except (FileNotFoundError, PermissionError, NotADirectoryError):
|
||||
return None
|
||||
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ def _create_stub_map(directory_path_info):
|
||||
def generate():
|
||||
try:
|
||||
listed = os.listdir(directory_path_info.path)
|
||||
except FileNotFoundError:
|
||||
except (FileNotFoundError, NotADirectoryError):
|
||||
return
|
||||
|
||||
for entry in listed:
|
||||
|
||||
Reference in New Issue
Block a user