Adapt small changes in parso's FileIO

This commit is contained in:
Dave Halter
2019-05-22 00:03:01 +02:00
parent c64ee8a07c
commit c05629b3de
2 changed files with 5 additions and 1 deletions

View File

@@ -98,7 +98,10 @@ class ZipFileIO(KnownContentFileIO):
self._zip_path = zip_path
def get_last_modified(self):
return os.path.getmtime(self._zip_path)
try:
return os.path.getmtime(self._zip_path)
except OSError: # Python 3 would probably only need FileNotFoundError
return None
def _from_loader(loader, string):

View File

@@ -122,6 +122,7 @@ class TreeNameDefinition(AbstractTreeName):
class ParamNameInterface(object):
# annotation default?!
def get_kind(self):
raise NotImplementedError