From 224966a18ccd5f265de83195a065730cf0663249 Mon Sep 17 00:00:00 2001 From: "Ilya.Kazakevich" Date: Thu, 4 May 2017 22:54:58 +0300 Subject: [PATCH] PY-24111: FileNotFoundError is Py3 only, use general OSError which is available in Py2 --- python/helpers/pycharm/_jb_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python/helpers/pycharm/_jb_utils.py b/python/helpers/pycharm/_jb_utils.py index c0025820503f..40a359836fcd 100644 --- a/python/helpers/pycharm/_jb_utils.py +++ b/python/helpers/pycharm/_jb_utils.py @@ -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