PY-24111: FileNotFoundError is Py3 only, use general OSError which is available in Py2

This commit is contained in:
Ilya.Kazakevich
2017-05-04 23:06:25 +03:00
parent 06f4ef5bdd
commit 224966a18c
+1 -1
View File
@@ -24,7 +24,7 @@ class FileChangesTracker(object):
for file in map(lambda f: os.path.join(tmp_folder, f), files):
try:
result.update({file: os.path.getmtime(file)})
except FileNotFoundError: # on Windows long path may lead to it: PY-23386
except OSError: # on Windows long path may lead to it: PY-23386
message = "PyCharm can't check if the following file been updated: {0}\n".format(str(file))
sys.stderr.write(message)
return result