MCPcopy Index your code
hub / github.com/python/cpython / _extract_text_encoding

Function _extract_text_encoding

Lib/zipfile/_path/__init__.py:197–204  ·  view source on GitHub ↗
(encoding=None, *args, **kwargs)

Source from the content-addressed store, hash-verified

195
196
197def _extract_text_encoding(encoding=None, *args, **kwargs):
198 # compute stack level so that the caller of the caller sees any warning.
199 is_pypy = sys.implementation.name == 'pypy'
200 # PyPy no longer special cased after 7.3.19 (or maybe 7.3.18)
201 # See jaraco/zipp#143
202 is_old_pypi = is_pypy and sys.pypy_version_info < (7, 3, 19)
203 stack_level = 3 + is_old_pypi
204 return io.text_encoding(encoding, stack_level), args, kwargs
205
206
207class Path:

Callers 2

openMethod · 0.85
read_textMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…