forked from p15670423/monkey
Intentional shadowing of builtins
This commit is contained in:
parent
4b0ea4aed7
commit
fd70ecfe29
|
@ -52,6 +52,7 @@ def virtual_path(name):
|
||||||
return "%s%s" % (MONKEYFS_PREFIX, name)
|
return "%s%s" % (MONKEYFS_PREFIX, name)
|
||||||
|
|
||||||
|
|
||||||
|
# noinspection PyShadowingBuiltins
|
||||||
def open(name, mode='r', buffering=-1):
|
def open(name, mode='r', buffering=-1):
|
||||||
# use normal open for regular paths, and our "virtual" open for monkeyfs:// paths
|
# use normal open for regular paths, and our "virtual" open for monkeyfs:// paths
|
||||||
if name.startswith(MONKEYFS_PREFIX):
|
if name.startswith(MONKEYFS_PREFIX):
|
||||||
|
|
|
@ -16,6 +16,7 @@ LOG = logging.getLogger(__name__)
|
||||||
try:
|
try:
|
||||||
WindowsError
|
WindowsError
|
||||||
except NameError:
|
except NameError:
|
||||||
|
# noinspection PyShadowingBuiltins
|
||||||
WindowsError = psutil.AccessDenied
|
WindowsError = psutil.AccessDenied
|
||||||
|
|
||||||
__author__ = 'uri'
|
__author__ = 'uri'
|
||||||
|
|
Loading…
Reference in New Issue