Intentional shadowing of builtins

This commit is contained in:
Shay Nehmad 2019-10-28 16:15:52 +02:00
parent 4b0ea4aed7
commit fd70ecfe29
2 changed files with 2 additions and 0 deletions

View File

@ -52,6 +52,7 @@ def virtual_path(name):
return "%s%s" % (MONKEYFS_PREFIX, name)
# noinspection PyShadowingBuiltins
def open(name, mode='r', buffering=-1):
# use normal open for regular paths, and our "virtual" open for monkeyfs:// paths
if name.startswith(MONKEYFS_PREFIX):

View File

@ -16,6 +16,7 @@ LOG = logging.getLogger(__name__)
try:
WindowsError
except NameError:
# noinspection PyShadowingBuiltins
WindowsError = psutil.AccessDenied
__author__ = 'uri'