aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/tools/cython
diff options
context:
space:
mode:
authoriaz1607 <iaz1607@yandex-team.ru>2022-02-10 16:45:37 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:45:37 +0300
commit94e51c602b555459333b3c6ae92476c424c930bc (patch)
treeb2cc84ee7850122e7ccf51d0ea21e4fa7e7a5685 /contrib/tools/cython
parente5437feb4ac2d2dc044e1090b9312dde5ef197e0 (diff)
downloadydb-94e51c602b555459333b3c6ae92476c424c930bc.tar.gz
Restoring authorship annotation for <iaz1607@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'contrib/tools/cython')
-rw-r--r--contrib/tools/cython/Cython/Coverage.py22
-rw-r--r--contrib/tools/cython/Cython/ya.make2
2 files changed, 12 insertions, 12 deletions
diff --git a/contrib/tools/cython/Cython/Coverage.py b/contrib/tools/cython/Cython/Coverage.py
index 3078fc9d47..5aa9df2ce0 100644
--- a/contrib/tools/cython/Cython/Coverage.py
+++ b/contrib/tools/cython/Cython/Coverage.py
@@ -163,8 +163,8 @@ class Plugin(CoveragePlugin):
py_source_file = None
try:
- with OpenFile(c_file) as f:
- if '/* Generated by Cython ' not in f.read(30):
+ with OpenFile(c_file) as f:
+ if '/* Generated by Cython ' not in f.read(30):
return None, None # not a Cython file
except (IOError, OSError):
c_file = None
@@ -181,8 +181,8 @@ class Plugin(CoveragePlugin):
broot = os.environ['PYTHON_COVERAGE_CYTHON_BUILD_ROOT']
iter_files = lambda: (os.path.join(root, filename) for root, _, files in os.walk(broot) for filename in files)
else:
- import library.python.resource
- iter_files = library.python.resource.resfs_files
+ import library.python.resource
+ iter_files = library.python.resource.resfs_files
for c_file in iter_files():
if os.path.splitext(c_file)[1] in C_FILE_EXTENSIONS:
self._read_source_lines(c_file, source_file)
@@ -409,12 +409,12 @@ class OpenFile(object):
self.file = open(os.path.join(self.build_root, self.filename), self.mode)
return self.file
elif standalone():
- import library.python.resource
- from six import StringIO
+ import library.python.resource
+ from six import StringIO
- content = library.python.resource.resfs_read(self.filename, builtin=True)
+ content = library.python.resource.resfs_read(self.filename, builtin=True)
assert content, (self.filename, os.environ.items())
- return StringIO(content.decode())
+ return StringIO(content.decode())
else:
self.file = open(self.filename, self.mode)
return self.file
@@ -449,14 +449,14 @@ if standalone():
else:
# Trace stage (test's runtime)
def exists(filename):
- import library.python.resource
- return library.python.resource.resfs_src(filename, resfs_file=True)
+ import library.python.resource
+ return library.python.resource.resfs_src(filename, resfs_file=True)
if os.environ.get('PYTHON_COVERAGE_CYTHON_INCLUDE_MAP'):
if CYTHON_INCLUDE_MAP.get('undef'):
with open(os.environ['PYTHON_COVERAGE_CYTHON_INCLUDE_MAP']) as afile:
data = json.load(afile)
- data = {os.path.splitext(k)[0]: v for k, v in data.items()}
+ data = {os.path.splitext(k)[0]: v for k, v in data.items()}
CYTHON_INCLUDE_MAP.clear()
CYTHON_INCLUDE_MAP.update(data)
diff --git a/contrib/tools/cython/Cython/ya.make b/contrib/tools/cython/Cython/ya.make
index 16c2b59c66..f4aacbdf94 100644
--- a/contrib/tools/cython/Cython/ya.make
+++ b/contrib/tools/cython/Cython/ya.make
@@ -14,7 +14,7 @@ PY_SRCS(
PEERDIR(
contrib/python/six
- library/python/resource
+ library/python/resource
)
END()