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:30 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:44:30 +0300
commit2598ef1d0aee359b4b6d5fdd1758916d5907d04f (patch)
tree012bb94d777798f1f56ac1cec429509766d05181 /contrib/python/py/patches/01-arcadia.patch
parent6751af0b0c1b952fede40b19b71da8025b5d8bcf (diff)
downloadydb-2598ef1d0aee359b4b6d5fdd1758916d5907d04f.tar.gz
Restoring authorship annotation for <shadchin@yandex-team.ru>. Commit 1 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 5739c8689f6..8223e2e488a 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: