aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/python/py/patches/01-arcadia.patch
diff options
context:
space:
mode:
authorshadchin <shadchin@yandex-team.ru>2022-02-10 16:44:39 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:44:39 +0300
commite9656aae26e0358d5378e5b63dcac5c8dbe0e4d0 (patch)
tree64175d5cadab313b3e7039ebaa06c5bc3295e274 /contrib/python/py/patches/01-arcadia.patch
parent2598ef1d0aee359b4b6d5fdd1758916d5907d04f (diff)
downloadydb-e9656aae26e0358d5378e5b63dcac5c8dbe0e4d0.tar.gz
Restoring authorship annotation for <shadchin@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'contrib/python/py/patches/01-arcadia.patch')
-rw-r--r--contrib/python/py/patches/01-arcadia.patch54
1 files changed, 27 insertions, 27 deletions
diff --git a/contrib/python/py/patches/01-arcadia.patch b/contrib/python/py/patches/01-arcadia.patch
index 8223e2e488a..5739c8689f6 100644
--- a/contrib/python/py/patches/01-arcadia.patch
+++ b/contrib/python/py/patches/01-arcadia.patch
@@ -1,27 +1,27 @@
---- contrib/python/py/py/_vendored_packages/iniconfig/__init__.py (working tree)
-+++ contrib/python/py/py/_vendored_packages/iniconfig/__init__.py (index)
-@@ -1,6 +1,8 @@
- """ brain-dead simple parser for ini-style files.
- (C) Ronny Pfannschmidt, Holger Krekel -- MIT licensed
- """
-+import io
-+
- __all__ = ['IniConfig', 'ParseError']
-
- COMMENTCHARS = "#;"
-@@ -49,7 +51,14 @@
- def __init__(self, path, data=None):
- self.path = str(path) # convenience
- if data is None:
-- f = open(self.path)
-+ if self.path.startswith('pkg:'):
-+ import pkgutil
-+
-+ _, package, resource = self.path.split(':')
-+ content = pkgutil.get_data(package, resource)
-+ f = io.StringIO(content.decode('utf-8'))
-+ else:
-+ f = open(self.path)
- try:
- tokens = self._parse(iter(f))
- finally:
+--- contrib/python/py/py/_vendored_packages/iniconfig/__init__.py (working tree)
++++ contrib/python/py/py/_vendored_packages/iniconfig/__init__.py (index)
+@@ -1,6 +1,8 @@
+ """ brain-dead simple parser for ini-style files.
+ (C) Ronny Pfannschmidt, Holger Krekel -- MIT licensed
+ """
++import io
++
+ __all__ = ['IniConfig', 'ParseError']
+
+ COMMENTCHARS = "#;"
+@@ -49,7 +51,14 @@
+ def __init__(self, path, data=None):
+ self.path = str(path) # convenience
+ if data is None:
+- f = open(self.path)
++ if self.path.startswith('pkg:'):
++ import pkgutil
++
++ _, package, resource = self.path.split(':')
++ content = pkgutil.get_data(package, resource)
++ f = io.StringIO(content.decode('utf-8'))
++ else:
++ f = open(self.path)
+ try:
+ tokens = self._parse(iter(f))
+ finally: